Jump to content

ayaycaptainchris

New Members
  • Posts

    3
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

ayaycaptainchris's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. [!--quoteo(post=385930:date=Jun 20 2006, 05:11 AM:name=wildteen88)--][div class=\'quotetop\']QUOTE(wildteen88 @ Jun 20 2006, 05:11 AM) [snapback]385930[/snapback][/div][div class=\'quotemain\'][!--quotec--] If your file is 450Kb it wont be taking any bandwidth as it isnt acutlly sending that 450Kb file to the client. The thing that uses the bandwidth is the ouput, For example if you had a php script which is 1MB in size and all it did was return a simple hello world message which will come to less than 1K. It'll only take 1K out of your alloted bandwidth. The only problem that will happen is the amount of time it'll take PHP to parse the 1MB file. [/quote] thank you! but still, there are functions that only work on some of the DO= something pages and its loading everytime the that page is accessed. i made it require a function_test.php file with an IF statement. thank you for your reply. i still need answer to my question though.
  2. I got this really huge file (lets say its called index.php). i i decided to cut it into chunks. basically. im wondering with this code <?php if($_GET['do']=="test"){ include ("include_test.php"); if($_GET['do']=="test2"){ include ("include_test2.php"); } ?> if i just access index.php, it will only load index.php. my question is...will it also load include_test.php and include_test2.php and just NOT show it? or...obviously with the if statement, it will only include include_test.php if do=test. i know my question is simple, but i needa make sure. i needa reduce my bandwidth usage and i think this one is a simple solution i cut the original file from 450 kb to now only 35 but it has a lot of includes. i need to know if it loads the includes and just not show it (hence bandwidth is not really reduce) or it only loads it only if the IF statement is true. thank you. i hope youunderstood my question
  3. I am trying to modify a premade php calendar that i have found, but cant seem to make it work. i have been trying for days to achieve this, but i have failed. basically, the premade php calendar has the code: [code] $days = array(     2=>array('/weblog/archive/2004/Jan/02','linked-day'),     3=>array('/weblog/archive/2004/Jan/03','linked-day'),     8=>array('/weblog/archive/2004/Jan/08','linked-day'),     22=>array('/weblog/archive/2004/Jan/22','linked-day'), ); [/code] I want to chagne it to something that accesses the database. I have a table called "calendar" in my database [!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--] DATE MONTH LINK EVENT 3 May [a href=\"http://www.3.com\" target=\"_blank\"]http://www.3.com[/a] Test 4 May [a href=\"http://www.4.com\" target=\"_blank\"]http://www.4.com[/a] Test 2 5 May [a href=\"http://www.5.com\" target=\"_blank\"]http://www.5.com[/a] Test 3 6 May [a href=\"http://www.6.com\" target=\"_blank\"]http://www.6.com[/a] Test 4 [/quote] and i want it to transform to [code] $sql = mysql_query("SELECT date, month, link, event FROM calendar where month='May'"); $row = mysql_fetch_array($sql); $date = $row['date']; $month = $row['month']; $link = $row['link']; $event = $row['event']; $days = array(     $date=>array('$link', '$event'), ); [/code] it's not working. can someone please help me. basically, it should end up like [code] $days = array(     3=>array('http://www.3.com','Test'),     4=>array('http://www.4.com','Test 2'),     5=>array('http://www.5.com','Test 3'),     6=>array('http://www.6.com','Test 4'), ); [/code]
×
×
  • 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.