Jump to content

mamabear0604

New Members
  • Posts

    8
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

mamabear0604's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I am very sorry. I was going to paste the section of code that I thought I needed edited. But then didnt know if I would need to attach the whole thing. So I apologize for my mistake. The script itself is an adult tube script. The rest of the menu items point to what I want them to. I am just wanting to add 2 new menu items to the script. I thought I could simply add the items in by copying a line before then changing the names and urls. This didnt work, it gave me some unexpected errors. Which I know that sometimes is an extra ' or : but wasnt sure how to go about correcting it as I didnt see what needed to be changed. The script itself sets in the favs directory and the menu items I am wanting to add sets in the wp directory. So is it possible to add the menu items to the script and when clicked they go to a page in the wp directory? (i hope that makes sense) The code I think I need to change sets in the functions.php. the specific section is below function call_menuler() { global $root_url,$lcl; return '<li><a href="'.$root_url.'">'.$lcl['homepage'].'</a></li> <li><a href="'.$root_url.'">'.$lcl['videos'].'</a></li> <li><a href="'.$root_url.'?option=popular">'.$lcl['popularvideos'].'</a></li> <li><a href="'.$root_url.'?option=games">'.$lcl['games'].'</a></li> <li><a href="'.$root_url.'?option=populargames">'.$lcl['populargames'].'</a></li> <li><a href="'.$root_url.'?option=contact">'.$lcl['contact'].'</a></li>'; } I can tell that this is the menu, but not sure how to add the things I want. I appreciate any help I am offered. If you need any more information, please just ask I will aid in any way possible. Ty again
  2. I have a script where I would like to modify the menu. My site is (CONTAINS ADULT CONTENT) http://www.wettspott.com/favs/ I would like to add Premium Membership and Vip Membership to the menu. Each menu item goes to a different directory on my site. Vip would go to (CONTAINS ADULT CONTENT) http://wettspott.com/wp/?page_id=190 & Premium would go to (CONTAINS ADULT CONTENT) http://wettspott.com/wp/?page_id=188. I believe the code I need to modify is attached. But I dont know how to do it. I tried a couple different things and it didnt work. [attachment deleted by admin]
  3. Got it done thread can be closed. TY for all your help
  4. I also corrected the line of code that you said. and now it says Updating: 1 Unknown column 'date' in 'field list' Boy the site I pulled this off of had some big errors in it. Ty for your help
  5. got that fixed forgot to add my user.
  6. well i got almost all the errors over with. now its telling me No database selected <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> </head> <body><?php // define mysql connect $dbname = "*****"; $dbuser = "*****"; $dbpass = "*****"; $dbhost = "localhost"; // this will usually stay 'localhost' $my_table = "pa_videos"; // define wordpress table name $gmt_offset = '-6'; // -8 for California, -5 New York, -6 Missouri etc. // I'm setting into the future year so WordPress can publish as , else I would use 1 for min and 60 for max, for last 2 months. $min_days_old = -365; // the minimum number of days old $max_days_old = 7; // the maximum number of days old // connect to db mysql_connect($dbhost,$dbuser,$dbpass); mysql_select_db($dbname); $result = mysql_query("SELECT ID FROM $my_table") or die(mysql_error()); while ($l = mysql_fetch_array($result)) { $post_id = $l['ID']; echo "Updating: $post_id "; $day = rand($min_days_old, $max_days_old); $hour = rand(0, 23); $new_date = date( 'Y-m-d H:i:s', strtotime("-$day day -$hour hour" ) ); $gmt_new_date = date( 'Y-m-d H:i:s', strtotime("-$day day -$hour hour -$gmt_offset hour" ) ); mysql_query("UPDATE $my_table SET date='$new_date' WHERE ID='$post_id'" ) or die(mysql_error()); } echo "DONE!"; ?> Am i missing something somewhere. What this is suppose to do is randomize post dates for a wordpress blog. I already have the code for pulling the posts out of myphpadmin. I just want to randomize dates for the posts. Ty so much for your help.
  7. Ok I went through and corrected the smart quotes. and the echo and now i am getting this Parse error: syntax error, unexpected T_STRING in /home/mamabear/public_html/wordpressdate.php on line 35 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> </head> <body><?php // define mysql connect $dbname = "*****"; $dbuser = "*****"; $dbpass = "*****"; $dbhost = "localhost"; // this will usually stay 'localhost' $my_table = "pa-videos"; // define wordpress table name $gmt_offset = '-6'; // -8 for California, -5 New York, -6 Missouri etc. // I'm setting into the future year so WordPress can publish as , else I would use 1 for min and 60 for max, for last 2 months. $min_days_old = -365; // the minimum number of days old $max_days_old = 7; // the maximum number of days old // connect to db mysql_connect($dbhost,$dbuser,$dbpass); mysql_select_db($dbname); $result = mysql_query("SELECT ID FROM $my_table") or die(mysql_error()); while ($l = mysql_fetch_array($result)) { $post_id = $l['ID']; echo "Updating: $post_id "; $day = rand($min_days_old, $max_days_old); $hour = rand(0, 23); $new_date = date;( ‘Y-m-d H:i:s’, strtotime("-$day day -$hour hour" ) ); $gmt_new_date = date( ‘Y-m-d H:i:s’, strtotime("-$day day -$hour hour -$gmt_offset hour" ) ); mysql_query("UPDATE $my_table SET date=’$new_date’ WHERE ID=’$post_id’" ) or die(mysql_error))); } echo "DONE!"; ?> Line 35 $new_date = date;( ‘Y-m-d H:i:s’, strtotime("-$day day -$hour hour" ) );
  8. Parse error: syntax error, unexpected $end in /home/mamabear/public_html/wordpressdate.php on line 46 I have googled this as well as combed through several forums. I have tried editing this code, but for the life of me I just can't seem to figure out what is casuing this error. I am sure by now everything is starting to look the same after staring at it for hours. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> </head> <body><?php // define mysql connect $dbname = "*****"; $dbuser = "*****"; $dbpass = "*****"; $dbhost = "localhost"; // this will usually stay 'localhost' $my_table = "pa-videos"; // define wordpress table name $gmt_offset = '-6'; // -8 for California, -5 New York, -6 Missouri etc. // I'm setting into the future year so WordPress can publish as , else I would use 1 for min and 60 for max, for last 2 months. $min_days_old = -365; // the minimum number of days old $max_days_old = 7; // the maximum number of days old // connect to db mysql_connect($dbhost,$dbuser,$dbpass); mysql_select_db($dbname); $result = mysql_query("SELECT ID FROM $my_table") or die(mysql_error()); while ($l = mysql_fetch_array($result)) { $post_id = $l['ID']; echo "Updating: $post_id “; $day = rand($min_days_old, $max_days_old); $hour = rand(0, 23); $new_date = date;( ‘Y-m-d H:i:s’, strtotime(“-$day day -$hour hour” ) ); $gmt_new_date = date( ‘Y-m-d H:i:s’, strtotime(“-$day day -$hour hour -$gmt_offset hour” ) ); mysql_query(“UPDATE $my_table SET date=’$new_date’ WHERE ID=’$post_id’” ) or die(mysql_error))); } echo “ DONE!”; ?> PLEASE help. I appreciate any help and support someone is able to offer. TY
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.