Jump to content

Trying to find a person who is good with computers


nikogiant2

Recommended Posts

what scripts are they...can you post them, what is the filenames and extensions, etc, etc

 

 

 

 

 

 

 

I would just write my own scripts if you dont know how get a book on php and my sql and get lots of free time and patience

Link to comment
Share on other sites

k they are scripts here are some

 

 

 

 

 

 

 

<?php

 

 

 

//===========================================================================\\

 

 

 

// Aardvark Topsites PHP 5 \\

 

 

 

// Copyright © 2003-2005 Jeremy Scheff. All rights reserved. \\

 

 

 

//---------------------------------------------------------------------------\\

 

 

 

// http://www.avatic.com/ \\

 

 

 

//---------------------------------------------------------------------------\\

 

 

 

// This program is free software; you can redistribute it and/or modify it \\

 

 

 

// under the terms of the GNU General Public License as published by the \\

 

 

 

// Free Software Foundation; either version 2 of the License, or (at your \\

 

 

 

// option) any later version. \\

 

 

 

// \\

 

 

 

// This program is distributed in the hope that it will be useful, but \\

 

 

 

// WITHOUT ANY WARRANTY; without even the implied warranty of \\

 

 

 

// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General \\

 

 

 

// Public License for more details. \\

 

 

 

//===========================================================================\\

 

 

 

 

 

 

 

class skin {

 

 

 

var $filename;

 

 

 

 

 

 

 

function skin($filename) {

 

 

 

$this->filename = $filename;

 

 

 

}

 

 

 

 

 

 

 

function make() {

 

 

 

global $CONF, $TMPL;

 

 

 

 

 

 

 

$file = "{$CONF['skins_path']}/{$TMPL['skin_name']}/{$this->filename}.html";

 

 

 

$fh_skin = fopen($file, 'r');

 

 

 

$skin = @fread($fh_skin, filesize($file));

 

 

 

fclose($fh_skin);

 

 

 

 

 

 

 

$parse = 1;

 

 

 

 

 

 

 

if ($this->filename == 'wrapper') {

 

 

 

$powered_by_check = strpos($skin, '{$powered_by}') ? 1 : 0;

 

 

 

 

 

 

 

if ($powered_by_check) {

 

 

 

$return = $skin;

 

 

 

}

 

 

 

else {

 

 

 

$return = 'You cannot delete {$powered_by} from wrapper.html.';

 

 

 

$parse = 0;

 

 

 

}

 

 

 

}

 

 

 

elseif ($this->filename == 'admin' || $this->filename == 'ssi_top' || $this->filename == 'ssi_members') {

 

 

 

$return = $skin;

 

 

 

}

 

 

 

else {

 

 

 

$return = "\n{$skin}\n\n";

 

 

 

}

 

 

 

 

 

 

 

if ($parse) {

 

 

 

return $this->parse($return);

 

 

 

}

 

 

 

else {

 

 

 

return $return;

 

 

 

}

 

 

 

}

 

 

 

 

 

 

 

function send_email($email) {

 

 

 

global $CONF, $TMPL;

 

 

 

 

 

 

 

$file = "{$CONF['skins_path']}/{$TMPL['skin_name']}/{$this->filename}.html";

 

 

 

$fh_skin = fopen($file, "r");

 

 

 

$skin = @fread($fh_skin, filesize($file));

 

 

 

fclose($fh_skin);

 

 

 

 

 

 

 

$skin_array = explode("\n", $skin);

 

 

 

 

 

 

 

$subject = array_shift($skin_array);

 

 

 

$subject = str_replace('Subject: ', '', $subject);

 

 

 

$body = implode("\n", $skin_array);

 

 

 

 

 

 

 

$subject = $this->parse($subject);

 

 

 

$body = $this->parse($body);

 

 

 

 

 

 

 

mail($email, $subject, $body, "From: {$CONF['your_email']}\r\n");

 

 

 

}

 

 

 

 

 

 

 

function parse($skin) {

 

 

 

global $LNG, $TMPL;

 

 

 

 

 

 

 

$skin = preg_replace('/{\$lng->(.+?)}/ei', "\$LNG['\\1']", $skin);

 

 

 

$skin = preg_replace('/{include \"(.+?)\"}/ei', "file_get_contents('\\1')", $skin);

 

 

 

$skin = preg_replace('/{\$(.+?)}/ei', "\$TMPL['\\1']", $skin);

 

 

 

return $skin;

 

 

 

}

 

 

 

}

 

 

 

 

 

 

 

class main_skin extends skin {

 

 

 

function main_skin($filename) {

 

 

 

global $CONF, $DB, $FORM, $LNG, $TIMER, $TMPL;

 

 

 

 

 

 

 

$this->filename = $filename;

 

 

 

 

 

 

 

// Number of members

 

 

 

list($TMPL['num_members']) = $DB->fetch('SELECT COUNT(*) FROM '.$CONF['sql_prefix'].'_sites WHERE active = 1', __FILE__, __LINE__);

 

 

 

 

 

 

 

// Build the multiple pages menu

 

 

 

if ($TMPL['num_members'] > $CONF['num_list']) {

 

 

 

$num = $TMPL['num_members'];

 

 

 

$done = 0;

 

 

 

$TMPL['multiple_pages_menu'] = "\n";

 

 

 

while ($num > 0) {

 

 

 

$start = $done * $CONF['num_list'] + 1;

 

 

 

$end = ($done + 1) * $CONF['num_list'];

 

 

 

$FORM['start'] = isset($FORM['start']) ? $FORM['start'] : 1;

 

 

 

 

 

 

 

if ($FORM['start'] == $start) {

 

 

 

$TMPL['multiple_pages_menu'] .= "{$start} - {$end}\n";

 

 

 

}

 

 

 

else {

 

 

 

$TMPL['multiple_pages_menu'] .= "{$start} - {$end}\n";

 

 

 

}

 

 

 

 

 

 

 

$num = $num - $CONF['num_list'];

 

 

 

$done++;

 

 

 

}

 

 

 

$TMPL['multiple_pages_menu'] .= '';

 

 

 

}

 

 

 

else { $TMPL['multiple_pages_menu'] = ''; }

 

 

 

 

 

 

 

// Build the ranking method menu

 

 

 

$ranking_method = isset($FORM['method']) ? $FORM['method'] : $CONF['ranking_method'];

 

 

 

$TMPL['ranking_methods_menu'] = ''."\n";

 

 

 

if ($ranking_method == 'pv') { $TMPL['ranking_methods_menu'] .= ''.$LNG['g_pv']."\n"; }

 

 

 

else { $TMPL['ranking_methods_menu'] .= ''.$LNG['g_pv']."\n"; }

 

 

 

if ($ranking_method == 'in') { $TMPL['ranking_methods_menu'] .= ''.$LNG['g_in']."\n"; }

 

 

 

else { $TMPL['ranking_methods_menu'] .= ''.$LNG['g_in']."\n"; }

 

 

 

if ($ranking_method == 'out') { $TMPL['ranking_methods_menu'] .= ''.$LNG['g_out']."\n"; }

 

 

 

else { $TMPL['ranking_methods_menu'] .= ''.$LNG['g_out']."\n"; }

 

 

 

$TMPL['ranking_methods_menu'] .= '';

 

 

 

 

 

 

 

// Build the categories menu

 

 

 

$current_cat = isset($FORM['cat']) ? $FORM['cat'] : $LNG['main_all'];

 

 

 

$TMPL['categories_menu'] = "\n";

 

 

 

if ($current_cat == $LNG['main_all']) {

 

 

 

$TMPL['categories_menu'] .= "{$LNG['main_all']}\n";

 

 

 

}

 

 

 

else {

 

 

 

$TMPL['categories_menu'] .= "{$LNG['main_all']}\n";

 

 

 

}

 

 

 

foreach ($CONF['categories'] as $cat => $skin) {

 

 

 

if ($current_cat == $cat) {

 

 

 

$TMPL['categories_menu'] .= "{$cat}\n";

 

 

 

}

 

 

 

else {

 

 

 

$TMPL['categories_menu'] .= "{$cat}\n";

 

 

 

}

 

 

 

}

 

 

 

$TMPL['categories_menu'] .= '';

 

 

 

 

 

 

 

// Featured member

 

 

 

if ($CONF['featured_member'] && $TMPL['num_members']) {

 

 

 

$result = $DB->select_limit("SELECT username, url, title, description, banner_url FROM {$CONF['sql_prefix']}_sites WHERE active = 1 ORDER BY RAND()", 1, 0, __FILE__, __LINE__);

 

 

 

$row = $DB->fetch_array($result);

 

 

 

$TMPL = array_merge($TMPL, $row);

 

 

 

 

 

 

 

$TMPL['featured_member'] = base::do_skin('featured_member');

 

 

 

}

 

 

 

 

 

 

 

$TMPL['query'] = isset($TMPL['query']) ? $TMPL['query'] : '';

 

 

 

 

 

 

 

// Please do not remove the link to http://www.aardvarktopsitesphp.com/.

 

 

 

// This is a free script, all I ask for is a link back.

 

 

 

$TMPL['powered_by'] = $LNG['main_powered'].' Aardvark Topsites PHP '.$TMPL['version'];

 

 

 

$TMPL['powered_by'] .= '

 

Avatic | iTopsites | Consolidate Student Loan Consolidation';

 

 

 

 

 

 

 

$TMPL['num_queries'] = $DB->num_queries;

 

 

 

$TMPL['execution_time'] = $TIMER->get_time();

 

 

 

}

 

 

 

}

 

 

 

?>

 

 

 

 

 

 

 

thats one code

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.