Ad expire script php

Hi I need help I have a simple script that users, join and post ads, each ad has a id # but the ads do,nt have and expiring date ! looking for a simple script that I can set the date when ads expire through my admin,was thinking of using some kind of config file where I can edit the config file to set expiring dates of users ads .

The simplest way to do it is to add 3 columns to your ad table, 1 for the creation date, 1 for the expiration date, and 1 for whether its active or not. You can use strtotime() to add however many days or weeks it supposed to be active for. Set each ad to active by defaulyt.

Then, run another script through a cronjob that checks the expiration date against the current date. If its expired, then run an update query to set the ad to inactive or delete it, which ever you do. If you delete them, then don’t worry about using the active column.

Well…you can actually use 2 tables if you want, 1 to store the ad info and 1 to store the dates, it just makes it more complicated when you do the queries.

Thankyou im not good at making mysql tables just looing for something like a simple script with config file it would caat user id $row[ID] and read when to expire his ad . do,nt think theres anything like that lol

Well, you don’t have to use a database, but it would make things 100% easier than having to mess with file info. mysql really isn’t all that difficult to use, tons of tutorials here and other places. I used something similiar for an ad rotation script years ago. This is probably the simplest way of doing it with a database

ads table
id (primary key, auto increment)
ad_name (varchar 50)
ad_desc (varchar 50) for the alt attribute
ad_location (text) - image location
ad_imgname (char 50)
create_date - DATETIME
expire_date - DATETIME
active (int 1 default 1)

client sees these fields
ad name
ad description
file box
submit button

When the submit button is clicked, the script will grab the rest of the information.

this is a aboxcontent file that the ads showup in ether virtical or horozontal :
[php]<?PHP
if ($_GET[demo] == 1) {

$SQLbox        = "SELECT * from ADBOX WHERE ID = '$boxid'";
$resultbox     = mysql_query( $SQLbox ); 
$rowbox        = mysql_fetch_array( $resultbox );
$vari = "WHERE STATUS = 'Active' ORDER BY RAND() LIMIT $rowbox[MAXADS]";

} else {

$SQLf = "SELECT * from PACKAGES WHERE ID = '$boxid'"; 
$resultf = @mysql_query( $SQLf ); $rowf = @mysql_fetch_array( $resultf );

$SQLbox        = "SELECT * from ADBOX WHERE ID = '$rowf[ADBOX]'";
$resultbox     = mysql_query( $SQLbox ); 
$rowbox        = mysql_fetch_array( $resultbox );

$vari = "WHERE STATUS = 'Active' AND PACKAGE = '$boxid' ORDER BY RAND() LIMIT $rowbox[MAXADS]";

}
?>

<?PHP if ($rowbox[BOXTYPE] == Vertical) { ?> <?PHP $SQL = "SELECT * from LISTINGS $vari"; $result = mysql_query( $SQL ); while( $row = mysql_fetch_array( $result ) ) { ?> <?PHP //---------------------------------------------------- //---------------------------------------------------- $SQLview = "SELECT * from VIEW WHERE L_ID = '$row[ID]'"; $resultview = @mysql_query( $SQLview ); $rowview = @mysql_fetch_array( $resultview ); $newview = $rowview[VIEWS] + 1; if ($rowview[ID] == $nil) { $sqlup = "INSERT INTO VIEW SET VIEWS = '1', L_ID = '$row[ID]'"; $queryup = mysql_query($sqlup); } else { $sqlup = "UPDATE VIEW SET VIEWS = '$newview' WHERE L_ID = '$row[ID]'"; $queryup = mysql_query($sqlup); } //---------------------------------------------------- //---------------------------------------------------- ?> /* -- */ .vtextadsWIDTH { width: <?php echo $rowbox[WIDTH]; ?>; } .vtextadsBG { background-color: <?php echo $rowbox[BG]; ?>; border-top-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-top-style: <?php echo $rowbox[BORDERSTYLE]; ?>; border-top-color: <?php echo $rowbox[BORDERCOLOR]; ?>; border-bottom-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-bottom-style: <?php echo $rowbox[BORDERSTYLE]; ?>;; border-bottom-color: <?php echo $rowbox[BORDERCOLOR]; ?>; border-left-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-left-style: <?php echo $rowbox[BORDERSTYLE]; ?>;; border-left-color: <?php echo $rowbox[BORDERCOLOR]; ?>; border-right-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-right-style: <?php echo $rowbox[BORDERSTYLE]; ?>;; border-right-color: <?php echo $rowbox[BORDERCOLOR]; ?>; padding: <?php echo $rowbox[PADDING]; ?>; } .vtextadsTITLECOLOR a:link { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:<?php echo V_AD_TITLE_LINK; ?>;font-family:<?php echo V_AD_TITLE_FONT; ?>; font-size: <?php echo $rowbox[TITLESIZE]; ?>;text-shadow:<?php echo V_AD_LINK_SHADOW; ?>; } .vtextadsTITLECOLOR a:active { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:none; font-size: <?php echo $rowbox[TITLESIZE]; ?>; } .vtextadsTITLECOLOR a:visited { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:none; font-size: <?php echo $rowbox[TITLESIZE]; ?>; } .vtextadsTITLECOLOR a:hover { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:<?php echo V_AD_LINK_HOVER; ?>; font-size: <?php echo $rowbox[TITLESIZE]; ?>; } .vtextadsDESCCOLOR { color: <?php echo $rowbox[DESCCOLOR]; ?>;text-shadow:<?php echo V_AD_LINK_DEC__SHADOW; ?>; font-family: Arial, Helvetica, sans-serif;font-size:<?php echo V_AD_DEC_FONT_SIZE; ?>;} /* -- */
<A HREF="<?PHP ECHO $row[WEBSITE]; ?>" onclick="window.open('<?php echo $svr_urlscript; ?>/adbox/clickcounter.php?get_id=<?php echo $row[ID]; ?>','childWin','');return false;">
  <?php echo $row[TITLE]; ?>
  </A></span></strong><BR>
  <span class="vtextadsDESCCOLOR"><?php echo $row[DESCRIPTION]; ?></span>
</td>

<?PHP } ?> <?PHP } ?> <?PHP if ($rowbox[BOXTYPE] == Horizontal) { ?> <?PHP $SQL = "SELECT * from LISTINGS $vari"; $result = mysql_query( $SQL ); while( $row = mysql_fetch_array( $result ) ) { ?> <?PHP //---------------------------------------------------- //---------------------------------------------------- $SQLview = "SELECT * from VIEW WHERE L_ID = '$row[ID]'"; $resultview = @mysql_query( $SQLview ); $rowview = @mysql_fetch_array( $resultview ); $newview = $rowview[VIEWS] + 1; if ($rowview[ID] == $nil) { $sqlup = "INSERT INTO VIEW SET VIEWS = '1', L_ID = '$row[ID]'"; $queryup = mysql_query($sqlup); } else { $sqlup = "UPDATE VIEW SET VIEWS = '$newview' WHERE L_ID = '$row[ID]'"; $queryup = mysql_query($sqlup); } //---------------------------------------------------- //---------------------------------------------------- ?> /* -- */ .HtextadsWIDTH { width: <?php echo $rowbox[WIDTH]; ?>; } .HtextadsBG { background-color: <?php echo $rowbox[BG]; ?>; border-top-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-top-style: <?php echo $rowbox[BORDERSTYLE]; ?>; border-top-color: <?php echo $rowbox[BORDERCOLOR]; ?>; border-bottom-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-bottom-style: <?php echo $rowbox[BORDERSTYLE]; ?>;; border-bottom-color: <?php echo $rowbox[BORDERCOLOR]; ?>; border-left-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-left-style: <?php echo $rowbox[BORDERSTYLE]; ?>;; border-left-color: <?php echo $rowbox[BORDERCOLOR]; ?>; border-right-width: <?php echo $rowbox[BORDERSIZE]; ?>; border-right-style: <?php echo $rowbox[BORDERSTYLE]; ?>;; border-right-color: <?php echo $rowbox[BORDERCOLOR]; ?>; padding: <?php echo $rowbox[PADDING]; ?>; } .HtextadsTITLECOLOR a:link { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:<?php echo H_AD_TITLE_LINK; ?>; font-family:<?php echo H_AD_TITLE_FONT; ?>;font-size: <?php echo $rowbox[TITLESIZE]; ?>; text-shadow:<?php echo H_AD_LINK_SHADOW; ?>;} .HtextadsTITLECOLOR a:active { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:none; font-size: <?php echo $rowbox[TITLESIZE]; ?>; } .HtextadsTITLECOLOR a:visited { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:none; font-size: <?php echo $rowbox[TITLESIZE]; ?>; } .HtextadsTITLECOLOR a:hover { color: <?php echo $rowbox[TITLECOLOR]; ?>; text-decoration:<?php echo H_AD_LINK_HOVER; ?>; font-size: <?php echo $rowbox[TITLESIZE]; ?>; } .HtextadsDESCCOLOR { color: <?php echo $rowbox[DESCCOLOR]; ?>;text-shadow:<?php echo H_AD_LINK_DEC__SHADOW; ?>; font-family: Arial, Helvetica, sans-serif;font-size:<?php echo H_AD_DEC_FONT_SIZE; ?>;} /* -- */
<?php echo $row[TITLE]; ?>
<?php echo $row[DESCRIPTION]; ?>

<?PHP } ?> <?PHP } ?> <?PHP if ($rowbox[ADHERE] == Show || $rowbox[ADHERE] == '') {?>
( <? echo $adboxcontents_yr; ?> )
<?PHP } ?>

and heres a script from the internet i was trying to inplament into it i just do,nt know how to format it here :

$expiry = date(“Y-m-d”, time() + 302460*60 );

$today = date(“Y-m-d”, time());

if( $today > $expiry) {

ignore expired article

}
else
{

display article

}
?>[/php]

I was going to echo a config file to the + 302460*60 ); so i could control it through admin somehow

Unless you took code out, you’ve got a lot of missing quotes and semi-colons in there and a whole mess of unnecessary php tags in there.

That’s some overly complicated code just to do ads. I wouldn’t know where to being to made the modifications necessary to do what you need.

Hi here is the sql tables do,nt know witch table or where to ad create_date - DATETIME
expire_date - DATETIME and how to control it through admin, my guess is : first the way it works is user joins and creates a text ad of cource its inactive till ADmin activates it creates a compain ,ads are shown thorgh ID
Want to beable to ad a expration date so it would become inactive, been four days on this so far lol

sql table below:

DROP TABLE IF EXISTS ADBOX;

CREATE TABLE ADBOX (
ID int(11) NOT NULL auto_increment,
TITLE varchar(255) NOT NULL,
BOXTYPE varchar(255) NOT NULL,
MAXADS varchar(255) NOT NULL,
ADHERE varchar(255) NOT NULL,
WIDTH varchar(255) NOT NULL,
BG varchar(255) NOT NULL,
TITLECOLOR varchar(255) NOT NULL,
TITLESIZE varchar(255) NOT NULL,
DESCCOLOR varchar(255) NOT NULL,
BORDERCOLOR varchar(255) NOT NULL,
BORDERSTYLE varchar(255) NOT NULL,
BORDERSIZE varchar(255) NOT NULL,
PADDING varchar(255) NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=7 DEFAULT CHARSET=utf8;

INSERT INTO ADBOX VALUES(“1”,“Vertical Ad Box”,“Vertical”,“10”,“Show”,“200px”,"#B3B3FF","#000000",“17px”,"#000080",“0000ff”,“Dashed”,“1px”,“5”);
INSERT INTO ADBOX VALUES(“2”,“Hoizontal Ad Box “,“Horizontal”,“10”,“Show”,“468px”,“BFB3FB”,“0000ff”,“18px”,“0000000”,“A81C37”,“Solid”,“3px”,“10”);
INSERT INTO ADBOX VALUES(“3”,” Sample Virtical Ad Box”,“Vertical”,“1”,“Hide”,“200px”,“ffffff”,“0000ff”,“14px”,“0000000”,“0000ff”,“Dotted”,“3px”,“5”);
INSERT INTO ADBOX VALUES(“4”," Sample Hoizontal Banner Ad Box",“Horizontal”,“1”,“Hide”,“468px”,“ffffff”,“0000ff”,“14px”,“0000000”,“0000ff”,“Solid”,“3px”,“7”);
INSERT INTO ADBOX VALUES(“6”,“Hoizontal Ad Box foot”,“Horizontal”,“1”,“Show”,“468px”,“BFB3FB”,“0000ff”,“18px”,“0000000”,“A81C37”,“Solid”,“3px”,“10”);

DROP TABLE IF EXISTS LISTINGS;

CREATE TABLE LISTINGS (
ID int(11) NOT NULL auto_increment,
JBPOT text NOT NULL,
DA text NOT NULL,
MA text NOT NULL,
YA text NOT NULL,
DU text NOT NULL,
MU text NOT NULL,
YU text NOT NULL,
TITLE text NOT NULL,
CAPTION text NOT NULL,
DESCRIPTION text NOT NULL,
WEBSITE text NOT NULL,
STATUS text NOT NULL,
PACKAGE text NOT NULL,
PRICE int(20) NOT NULL,
OLDTITLE text NOT NULL,
OWNER text NOT NULL,
countdown2 text NOT NULL,
countdown text NOT NULL,
filler text NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=20 DEFAULT CHARSET=utf8;

INSERT INTO LISTINGS VALUES(“10”,"",“11”,“12”,“2012”,“16”,“12”,“2012”,“Php Software LLC”,"",“Quality php Scripts for website content.
\n”,“http://phpsoftware.info”,“Inactive”,“2”,“0”,“Php Software LLC”,“admin1”,“50”,“209”,“filler”);
INSERT INTO LISTINGS VALUES(“9”,"",“11”,“12”,“2012”,“11”,“12”,“2012”,“G&M Distribor LLC”,"",“Distributors of Spcaity woodworking Machinery , CNC Auto &
\nSemi-Auto Woodcopylathes & Tooling.”,“http://copylathe.com”,“Active”,"",“0”,"",“admin1”,"","","");
INSERT INTO LISTINGS VALUES(“11”,"",“11”,“12”,“2012”,“11”,“12”,“2012”,“Real Country 1320 AM”,"",“Real Country 1320 AM
\nis the newest and hottest
\ncountry station”,“http://realcountry1320.com/",“Active”,“3”,“0”,"",“admin1”,"","","”);
INSERT INTO LISTINGS VALUES(“14”,"",“12”,“12”,“2012”,“12”,“12”,“2012”,“Machine Post”,"",“Buy & Sell your suplus Machinery Here!”,“http://machinepost.net”,“Active”,“3”,“0”,"",“admin1”,"","","");
INSERT INTO LISTINGS VALUES(“15”,"",“12”,“12”,“2012”,“16”,“12”,“2012”,“LEAHY PRESS INC.”,"",“for all your printing needs.
\nThe professional Touch in Printing.”,“http://leahypress.com”,“Inactive”,“2”,“0”,“LEAHY PRESS INC.”,“admin1”,"","","");
INSERT INTO LISTINGS VALUES(“16”,"",“14”,“12”,“2012”,“14”,“12”,“2012”,“COPYLATHE.COM TEXT ADS”,"",“Advertise with us! at copylathe.com
\nview Impressions & Clicks.All in your control panel Unlimited AD editing FREE!.”,“http://phpsoftware.info/ad/index.php",“Active”,“5”,“0”,"COPYLATHE.COM TEXT ADS”,“admin1”,“50”,“135”,“filler”);
INSERT INTO LISTINGS VALUES(“17”,"",“16”,“12”,“2012”,“16”,“12”,“2012”,“Specail Used copylathe Offer! from G&M”,"",“We have a Year 2010 Used TC1200 LIKE NEW with four year warranty for Baseball bats or furniture parts production.Leadtime delivery:two weeks.
\nCall or email :
\n(802) 476-8354 or [email protected]”,“http://copylathe.com/tc1200.php",“Active”,“2”,“0”,"Specail Used copylathe Offer! from G&M”,“admin1”,“12”,“55”,“filler”);
INSERT INTO LISTINGS VALUES(“18”,"",“16”,“12”,“2012”,“16”,“12”,“2012”,“Specail Used Lathe Offer! from G&M 12/16/2012”,"",“We have a Year 2010 Used TC1200 LIKE NEW with four year warranty for Baseball bats or furniture parts.
\nThis lathe offer will not last…Leadtime delivery:two weeks. Call or email : (802) 476-8354 or [email protected]”,“http://copylathe.com/tc1200.php",“Active”,“5”,“0”,"Specail Used Lathe Offer! from G&M “,“admin1”,“50”,“250”,“filler”);
INSERT INTO LISTINGS VALUES(“19”,””,“16”,“12”,“2012”,“16”,“12”,“2012”,“Specail Used Lathe Offer! from G&M 12/16/2012”,"",“We have a Year 2010 Used TC1200 LIKE NEW with four year warranty for Baseball bats or furniture parts.
\nThis lathe offer will not last…Leadtime delivery:two weeks. Call or email : (802) 476-8354 or [email protected]”,“http://copylathe.com/tc1200.php",“Active”,“3”,“0”,"Specail Used Lathe Offer! from G&M 12/16/2012”,“admin1”,“50”,“250”,“filler”);

DROP TABLE IF EXISTS PACKAGES;

CREATE TABLE PACKAGES (
ID int(11) NOT NULL auto_increment,
NAME text NOT NULL,
LOGO text NOT NULL,
PHOTOLIMIT text NOT NULL,
RANK text NOT NULL,
DESCRIPTION text NOT NULL,
ADBOX text NOT NULL,
RECUR text NOT NULL,
PRICE1 text NOT NULL,
PRICE2 text NOT NULL,
PRICE3 text NOT NULL,
PRICE4 text NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8;

INSERT INTO PACKAGES VALUES(“2”,“Ad Package Virtical Ad”,"","","",“width 200x
\nOptional:
\nAutomatically Recurring or Non-Recurring”,“1”,“0”,"","","",“69.00”);
INSERT INTO PACKAGES VALUES(“3”,“Ad Package Horizontal Banner”,"","",""," width 468x
\n
\noptional:
\nAutomatically Recurring or Non-Recurring",“2”,“0”,"","","",“69.00”);
INSERT INTO PACKAGES VALUES(“5”,“Ad Package Horizontal Bottom “,””,"","",“On Bottom of every Page ad placement.468x60”,“6”,"","","","",“69.00”);

DROP TABLE IF EXISTS SETTINGS;

CREATE TABLE SETTINGS (
ID int(11) NOT NULL auto_increment,
LANGUAGE varchar(255) NOT NULL,
INSTALL varchar(255) NOT NULL,
TITLE varchar(255) NOT NULL,
WELCOMETITLE varchar(255) NOT NULL,
SITENAME3 varchar(255) NOT NULL,
DEFAULTPACKAGE varchar(255) NOT NULL,
STATUS varchar(255) NOT NULL,
STATUSCHANGE varchar(255) NOT NULL,
WELCOMETEXT text NOT NULL,
DIRECTORYNAME varchar(255) NOT NULL,
YOURNAME text NOT NULL,
EMAIL text NOT NULL,
SITENAMES text NOT NULL,
HELPBOX text NOT NULL,
MCTITLE text NOT NULL,
MCTEXT text NOT NULL,
CURRENCY text NOT NULL,
PAYPALEMAIL text NOT NULL,
STYLESHEET text NOT NULL,
METADESC text NOT NULL,
METAKEY text NOT NULL,
Submit text NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;

INSERT INTO SETTINGS VALUES(“1”,“default”,“1”,“PHP-TextAds”,“Welcome to G&M -TextAds! On www.copylathe.com.”,“G&M Distributor’s TextAds”,“1”,“Pending”,“1”,“This is a option advertizing Campaign system we offer our woodworking visitors to advertise on copylathe.com. <a href=index.php?page=register>Register free here ! and start creating your ad right away.
\nYou can monitor your text ads from your account control panel ,view Impressions & Clicks.All ads are optional Automatically Recurring or one time fee Non-Recurring and are Annual 12months Subscription .Your Ad will apear on all side panels of our site, & youl have unlimited ad editing to your exsiting ads anytime for no exstra charge.
\n
\n <a href=preview.php?boxid=3&demo=1>VIEW SAMPLE VIRTICAL TEXTAD
\n
\n<a href=preview.php?boxid=4&demo=1>VIEW SAMPLE HORIZONTAL BANNER TEXTAD”,“PHP-TextAds”,“G&M Webmaster","[email protected]”,“G&M Distributor Ads",“Show”,“50”,“250”,“USD”,"[email protected]”,“style/wood_work5.css”,"","",“Save”);

DROP TABLE IF EXISTS SUBSCRIPTIONS;

CREATE TABLE SUBSCRIPTIONS (
ID int(11) NOT NULL auto_increment,
D varchar(255) NOT NULL,
M varchar(255) NOT NULL,
Y varchar(255) NOT NULL,
H varchar(255) NOT NULL,
LISTING_ID varchar(255) NOT NULL,
PACKAGE_ID varchar(255) NOT NULL,
AMOUNT varchar(255) NOT NULL,
STATUS varchar(255) NOT NULL,
OWNER varchar(255) NOT NULL,
P1 varchar(255) NOT NULL,
P2 varchar(255) NOT NULL,
RECUR varchar(255) NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

DROP TABLE IF EXISTS USERS;

CREATE TABLE USERS (
ID int(11) NOT NULL auto_increment,
FIRSTNAME varchar(255) NOT NULL,
LASTNAME varchar(255) NOT NULL,
USERNAME varchar(255) NOT NULL,
PASSWORD varchar(255) NOT NULL,
EMAIL varchar(255) NOT NULL,
STATUS varchar(255) NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=utf8;

INSERT INTO USERS VALUES(“1”,"","",“admin1”,“admin1054”,"",“1”);
INSERT INTO USERS VALUES(“2”,"","",“admin1”,“admin1054”,"",“1”);
INSERT INTO USERS VALUES(“3”,"","",“mahmood”,“zxcvbnm”,“mahmood_twl2000@yahoo,com”,"");
INSERT INTO USERS VALUES(“4”,"","",“tdickey”,“trevor”,"[email protected]","");

DROP TABLE IF EXISTS VIEW;

CREATE TABLE VIEW (
ID int(11) NOT NULL auto_increment,
VIEWS varchar(255) NOT NULL,
L_ID varchar(255) NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=16 DEFAULT CHARSET=utf8;

INSERT INTO VIEW VALUES(“1”,“3”,“1”);
INSERT INTO VIEW VALUES(“2”,“262”,“2”);
INSERT INTO VIEW VALUES(“3”,“270”,“3”);
INSERT INTO VIEW VALUES(“4”,“136”,“7”);
INSERT INTO VIEW VALUES(“5”,“174”,“8”);
INSERT INTO VIEW VALUES(“6”,“50”,“9”);
INSERT INTO VIEW VALUES(“7”,“1202”,“10”);
INSERT INTO VIEW VALUES(“8”,“214”,“11”);
INSERT INTO VIEW VALUES(“9”,“102”,“12”);
INSERT INTO VIEW VALUES(“10”,“183”,“14”);
INSERT INTO VIEW VALUES(“11”,“1132”,“15”);
INSERT INTO VIEW VALUES(“12”,“534”,“16”);
INSERT INTO VIEW VALUES(“13”,“143”,“17”);
INSERT INTO VIEW VALUES(“14”,“77”,“18”);
INSERT INTO VIEW VALUES(“15”,“19”,“19”);

DROP TABLE IF EXISTS VISIT;

CREATE TABLE VISIT (
ID int(11) NOT NULL auto_increment,
VISITS varchar(255) NOT NULL,
L_ID varchar(255) NOT NULL,
PRIMARY KEY (ID)
) ENGINE=MyISAM AUTO_INCREMENT=14 DEFAULT CHARSET=utf8;

INSERT INTO VISIT VALUES(“1”,“1”,“2”);
INSERT INTO VISIT VALUES(“2”,“4”,“3”);
INSERT INTO VISIT VALUES(“3”,“1”,“7”);
INSERT INTO VISIT VALUES(“4”,“1”,“8”);
INSERT INTO VISIT VALUES(“5”,“1”,“9”);
INSERT INTO VISIT VALUES(“6”,“4”,“10”);
INSERT INTO VISIT VALUES(“7”,“2”,“15”);
INSERT INTO VISIT VALUES(“8”,“2”,“11”);
INSERT INTO VISIT VALUES(“9”,“1”,“14”);
INSERT INTO VISIT VALUES(“10”,“2”,“12”);
INSERT INTO VISIT VALUES(“11”,“1”,“16”);
INSERT INTO VISIT VALUES(“12”,“1”,“17”);
INSERT INTO VISIT VALUES(“13”,“1”,“18”);

please use code tags

DROP TABLE IF EXISTS `ADBOX`;

CREATE TABLE `ADBOX` (
  `ID` int(11) NOT NULL auto_increment,
  `TITLE` varchar(255) NOT NULL,
  `BOXTYPE` varchar(255) NOT NULL,
  `MAXADS` varchar(255) NOT NULL,
  `ADHERE` varchar(255) NOT NULL,
  `WIDTH` varchar(255) NOT NULL,
  `BG` varchar(255) NOT NULL,
  `TITLECOLOR` varchar(255) NOT NULL,
  `TITLESIZE` varchar(255) NOT NULL,
  `DESCCOLOR` varchar(255) NOT NULL,
  `BORDERCOLOR` varchar(255) NOT NULL,
  `BORDERSTYLE` varchar(255) NOT NULL,
  `BORDERSIZE` varchar(255) NOT NULL,
  `PADDING` varchar(255) NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=7 DEFAULT CHARSET=utf8;

INSERT INTO ADBOX VALUES("1","Vertical Ad Box","Vertical","10","Show","200px","#B3B3FF","#000000","17px","#000080","0000ff","Dashed","1px","5");
INSERT INTO ADBOX VALUES("2","Hoizontal  Ad Box ","Horizontal","10","Show","468px","BFB3FB","0000ff","18px","0000000","A81C37","Solid","3px","10");
INSERT INTO ADBOX VALUES("3"," Sample Virtical  Ad Box","Vertical","1","Hide","200px","ffffff","0000ff","14px","0000000","0000ff","Dotted","3px","5");
INSERT INTO ADBOX VALUES("4"," Sample Hoizontal  Banner Ad Box","Horizontal","1","Hide","468px","ffffff","0000ff","14px","0000000","0000ff","Solid","3px","7");
INSERT INTO ADBOX VALUES("6","Hoizontal  Ad Box foot","Horizontal","1","Show","468px","BFB3FB","0000ff","18px","0000000","A81C37","Solid","3px","10");



DROP TABLE IF EXISTS `LISTINGS`;

CREATE TABLE `LISTINGS` (
  `ID` int(11) NOT NULL auto_increment,
  `JBPOT` text NOT NULL,
  `DA` text NOT NULL,
  `MA` text NOT NULL,
  `YA` text NOT NULL,
  `DU` text NOT NULL,
  `MU` text NOT NULL,
  `YU` text NOT NULL,
  `TITLE` text NOT NULL,
  `CAPTION` text NOT NULL,
  `DESCRIPTION` text NOT NULL,
  `WEBSITE` text NOT NULL,
  `STATUS` text NOT NULL,
  `PACKAGE` text NOT NULL,
  `PRICE` int(20) NOT NULL,
  `OLDTITLE` text NOT NULL,
  `OWNER` text NOT NULL,
  `countdown2` text NOT NULL,
  `countdown` text NOT NULL,
  `filler` text NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=20 DEFAULT CHARSET=utf8;

INSERT INTO LISTINGS VALUES("10","","11","12","2012","16","12","2012","Php Software LLC","","Quality php Scripts for website content.
\n","http://phpsoftware.info","Inactive","2","0","Php Software LLC","admin1","50","209","filler");
INSERT INTO LISTINGS VALUES("9","","11","12","2012","11","12","2012","G&M Distribor LLC","","Distributors of Spcaity woodworking Machinery , CNC Auto &
\nSemi-Auto Woodcopylathes & Tooling.","http://copylathe.com","Active","","0","","admin1","","","");
INSERT INTO LISTINGS VALUES("11","","11","12","2012","11","12","2012","Real Country 1320 AM","","Real Country 1320 AM
\nis the newest and hottest
\ncountry station","http://realcountry1320.com/","Active","3","0","","admin1","","","");
INSERT INTO LISTINGS VALUES("14","","12","12","2012","12","12","2012","Machine Post","","Buy & Sell your suplus Machinery Here!","http://machinepost.net","Active","3","0","","admin1","","","");
INSERT INTO LISTINGS VALUES("15","","12","12","2012","16","12","2012","LEAHY PRESS INC.","","for all your printing needs.
\nThe professional Touch in Printing.","http://leahypress.com","Inactive","2","0","LEAHY PRESS INC.","admin1","","","");
INSERT INTO LISTINGS VALUES("16","","14","12","2012","14","12","2012","COPYLATHE.COM TEXT ADS","","Advertise with us! at copylathe.com
\nview Impressions & Clicks.All in your control panel Unlimited AD editing FREE!.","http://phpsoftware.info/ad/index.php","Active","5","0","COPYLATHE.COM TEXT ADS","admin1","50","135","filler");
INSERT INTO LISTINGS VALUES("17","","16","12","2012","16","12","2012","Specail Used copylathe Offer! from G&M","","We have a Year 2010 Used TC1200 LIKE NEW with four year warranty for Baseball bats or furniture parts production.Leadtime delivery:two weeks.
\nCall or email :
\n(802) 476-8354 or [email protected]","http://copylathe.com/tc1200.php","Active","2","0","Specail Used copylathe Offer! from G&M","admin1","12","55","filler");
INSERT INTO LISTINGS VALUES("18","","16","12","2012","16","12","2012","Specail Used Lathe Offer! from G&M  12/16/2012","","We have a Year 2010 Used TC1200 LIKE NEW with four year warranty for Baseball bats or furniture parts.
\nThis lathe offer will not last..Leadtime delivery:two weeks. Call or email : (802) 476-8354 or [email protected]","http://copylathe.com/tc1200.php","Active","5","0","Specail Used Lathe Offer! from G&M ","admin1","50","250","filler");
INSERT INTO LISTINGS VALUES("19","","16","12","2012","16","12","2012","Specail Used Lathe Offer! from G&M 12/16/2012","","We have a Year 2010 Used TC1200 LIKE NEW with four year warranty for Baseball bats or furniture parts.
\nThis lathe offer will not last..Leadtime delivery:two weeks. Call or email : (802) 476-8354 or [email protected]","http://copylathe.com/tc1200.php","Active","3","0","Specail Used Lathe Offer! from G&M 12/16/2012","admin1","50","250","filler");



DROP TABLE IF EXISTS `PACKAGES`;

CREATE TABLE `PACKAGES` (
  `ID` int(11) NOT NULL auto_increment,
  `NAME` text NOT NULL,
  `LOGO` text NOT NULL,
  `PHOTOLIMIT` text NOT NULL,
  `RANK` text NOT NULL,
  `DESCRIPTION` text NOT NULL,
  `ADBOX` text NOT NULL,
  `RECUR` text NOT NULL,
  `PRICE1` text NOT NULL,
  `PRICE2` text NOT NULL,
  `PRICE3` text NOT NULL,
  `PRICE4` text NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8;

INSERT INTO PACKAGES VALUES("2","Ad Package    Virtical  Ad","","","","width 200x
\nOptional:
\nAutomatically Recurring or Non-Recurring","1","0","","","","69.00");
INSERT INTO PACKAGES VALUES("3","Ad Package  Horizontal Banner","","",""," width 468x
\n
\noptional:
\nAutomatically Recurring or Non-Recurring","2","0","","","","69.00");
INSERT INTO PACKAGES VALUES("5","Ad Package  Horizontal  Bottom ","","","","On Bottom of every Page ad placement.468x60","6","","","","","69.00");



DROP TABLE IF EXISTS `SETTINGS`;

CREATE TABLE `SETTINGS` (
  `ID` int(11) NOT NULL auto_increment,
  `LANGUAGE` varchar(255) NOT NULL,
  `INSTALL` varchar(255) NOT NULL,
  `TITLE` varchar(255) NOT NULL,
  `WELCOMETITLE` varchar(255) NOT NULL,
  `SITENAME3` varchar(255) NOT NULL,
  `DEFAULTPACKAGE` varchar(255) NOT NULL,
  `STATUS` varchar(255) NOT NULL,
  `STATUSCHANGE` varchar(255) NOT NULL,
  `WELCOMETEXT` text NOT NULL,
  `DIRECTORYNAME` varchar(255) NOT NULL,
  `YOURNAME` text NOT NULL,
  `EMAIL` text NOT NULL,
  `SITENAMES` text NOT NULL,
  `HELPBOX` text NOT NULL,
  `MCTITLE` text NOT NULL,
  `MCTEXT` text NOT NULL,
  `CURRENCY` text NOT NULL,
  `PAYPALEMAIL` text NOT NULL,
  `STYLESHEET` text NOT NULL,
  `METADESC` text NOT NULL,
  `METAKEY` text NOT NULL,
  `Submit` text NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;

INSERT INTO SETTINGS VALUES("1","default","1","PHP-TextAds","Welcome to G&M -TextAds!  On www.copylathe.com.","G&M Distributor\'s TextAds","1","Pending","1","This is a option advertizing Campaign system we offer our woodworking visitors to advertise on copylathe.com. <b><a href=index.php?page=register>Register free here ! and start creating your ad right away.</a></b>
\nYou can  monitor your text ads from your account control panel ,view Impressions & Clicks.All ads are optional Automatically Recurring or one time fee  Non-Recurring and are Annual 12months Subscription .Your Ad will apear on all side panels of our site, & youl have unlimited ad editing to your exsiting ads anytime for no exstra charge.
\n
\n <b><a href=preview.php?boxid=3&demo=1>VIEW SAMPLE VIRTICAL TEXTAD</a></b>
\n
\n<b><a href=preview.php?boxid=4&demo=1>VIEW SAMPLE HORIZONTAL BANNER TEXTAD</a></b>","PHP-TextAds","G&M Webmaster","[email protected]","G&M Distributor Ads","Show","50","250","USD","[email protected]","style/wood_work5.css","","","Save");



DROP TABLE IF EXISTS `SUBSCRIPTIONS`;

CREATE TABLE `SUBSCRIPTIONS` (
  `ID` int(11) NOT NULL auto_increment,
  `D` varchar(255) NOT NULL,
  `M` varchar(255) NOT NULL,
  `Y` varchar(255) NOT NULL,
  `H` varchar(255) NOT NULL,
  `LISTING_ID` varchar(255) NOT NULL,
  `PACKAGE_ID` varchar(255) NOT NULL,
  `AMOUNT` varchar(255) NOT NULL,
  `STATUS` varchar(255) NOT NULL,
  `OWNER` varchar(255) NOT NULL,
  `P1` varchar(255) NOT NULL,
  `P2` varchar(255) NOT NULL,
  `RECUR` varchar(255) NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;




DROP TABLE IF EXISTS `USERS`;

CREATE TABLE `USERS` (
  `ID` int(11) NOT NULL auto_increment,
  `FIRSTNAME` varchar(255) NOT NULL,
  `LASTNAME` varchar(255) NOT NULL,
  `USERNAME` varchar(255) NOT NULL,
  `PASSWORD` varchar(255) NOT NULL,
  `EMAIL` varchar(255) NOT NULL,
  `STATUS` varchar(255) NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=utf8;

INSERT INTO USERS VALUES("1","","","admin1","admin1054","","1");
INSERT INTO USERS VALUES("2","","","admin1","admin1054","","1");
INSERT INTO USERS VALUES("3","","","mahmood","zxcvbnm","mahmood_twl2000@yahoo,com","");
INSERT INTO USERS VALUES("4","","","tdickey","trevor","[email protected]","");



DROP TABLE IF EXISTS `VIEW`;

CREATE TABLE `VIEW` (
  `ID` int(11) NOT NULL auto_increment,
  `VIEWS` varchar(255) NOT NULL,
  `L_ID` varchar(255) NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=16 DEFAULT CHARSET=utf8;

INSERT INTO VIEW VALUES("1","3","1");
INSERT INTO VIEW VALUES("2","262","2");
INSERT INTO VIEW VALUES("3","270","3");
INSERT INTO VIEW VALUES("4","136","7");
INSERT INTO VIEW VALUES("5","174","8");
INSERT INTO VIEW VALUES("6","50","9");
INSERT INTO VIEW VALUES("7","1202","10");
INSERT INTO VIEW VALUES("8","214","11");
INSERT INTO VIEW VALUES("9","102","12");
INSERT INTO VIEW VALUES("10","183","14");
INSERT INTO VIEW VALUES("11","1132","15");
INSERT INTO VIEW VALUES("12","534","16");
INSERT INTO VIEW VALUES("13","143","17");
INSERT INTO VIEW VALUES("14","77","18");
INSERT INTO VIEW VALUES("15","19","19");



DROP TABLE IF EXISTS `VISIT`;

CREATE TABLE `VISIT` (
  `ID` int(11) NOT NULL auto_increment,
  `VISITS` varchar(255) NOT NULL,
  `L_ID` varchar(255) NOT NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=14 DEFAULT CHARSET=utf8;

INSERT INTO VISIT VALUES("1","1","2");
INSERT INTO VISIT VALUES("2","4","3");
INSERT INTO VISIT VALUES("3","1","7");
INSERT INTO VISIT VALUES("4","1","8");
INSERT INTO VISIT VALUES("5","1","9");
INSERT INTO VISIT VALUES("6","4","10");
INSERT INTO VISIT VALUES("7","2","15");
INSERT INTO VISIT VALUES("8","2","11");
INSERT INTO VISIT VALUES("9","1","14");
INSERT INTO VISIT VALUES("10","2","12");
INSERT INTO VISIT VALUES("11","1","16");
INSERT INTO VISIT VALUES("12","1","17");
INSERT INTO VISIT VALUES("13","1","18");
Sponsor our Newsletter | Privacy Policy | Terms of Service