Thread: Confussion

    #1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    Comber, Belfast, United Kingdom
    Posts
    17
    Rep Power
    0
    Well im creating a php system where you go to a page and see any other page by putting ?page = bla after it. i have diferent parts of the pages in php3 files so the layout will stay the same and just the content will change. in each php3 file there is sometihng like
    <BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">code:</font><HR><pre><?php

    $indexc = "
    <p><font face="Arial, Helvetica, sans-serif">Welcome to RCT madness (RCTM
    for short). Over the next few weeks these pages will be created and enhanced.
    Dont forget to see <a href="http://www.thesims.co.uk">TheSims.co.uk</a>
    as they have kindly hosted us!</font></p>";

    ?>[/code]
    in the main pages has
    <BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">code:</font><HR><pre><?

    require("./head.php3");
    require("./bodytop.php3");
    require("./title.php3");
    require("./between.php3");
    require("./nav.php3");
    require("./bodybottom.php3");
    require("./parksc.php3");
    require("./tracksc.php3");
    require("./indexc.php3");
    require("./edc.php3");

    $index = "$head.$bodytop.$title.$between.$nav.$indexc.$bodybottom";
    $tracks = "$head.$bodytop.$title.$between.$nav.$tracksc.$bodybottom";
    $parks = "$head.$bodytop.$title.$between.$nav.$parksc.$bodybottom";
    $ed = "$head.$bodytop.$title.$between.$nav.$edc.$bodybottom";

    switch ($page)
    {

    case "home":
    echo $index;
    break;

    case "tracks":
    echo $tracks;
    break;

    case "parks":
    echo $parks;
    break;

    case "ed":
    echo $ed;
    break;

    default:
    echo $index;
    break;

    }
    ?>
    [/code] but i alsways get error messages like "parse error in /rctycoon/edc.php3 on line 4" (thats what i get for the short one) nad when i go to the big one it gives me hte same messages. all the other files that it requires consist of nameing a vabible and putting tags and html in it. could you help me please? I think it might be the ""s in the varibles but what do i do?

    ------------------


    [This message has been edited by Ed Mack (edited August 13, 2000).]

    [This message has been edited by Ed Mack (edited August 13, 2000).]
  2. #2
  3. chown python:users\ /world
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Location
    Texas Tech
    Posts
    95
    Rep Power
    15
    Can you post edc.php please?

    ------------------
    Hartmann
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2000
    Location
    Seaside, CA
    Posts
    84
    Rep Power
    15
    Well, hey, I don't have a clue since I don't know what's on "edc.php3 on line 4." But in that first portion of code you put up there you might want to either escape the quotes within quotes or use single quotes.

    ------------------
    From the day we're born, we're running out of time.
  6. #4
  7. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    Comber, Belfast, United Kingdom
    Posts
    17
    Rep Power
    0
    I need a way of putting " and $'s inside php varibles. Do you understand that? all the files are at http://www.thesims.co.uk/service/rctycoon/

    ------------------


    [This message has been edited by Ed Mack (edited August 13, 2000).]
  8. #5
  9. .Net Developer
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    London
    Posts
    987
    Rep Power
    15

    <<
    $indexc = " <p><font face="Arial, Helvetica, sans-serif">Welcome to RCT madness (RCTM for short). Over the next few weeks these pages will be created and enhanced. Dont forget to see <a href="http://www.thesims.co.uk">TheSims.co.uk</a> as they have kindly hosted us!</font></p>";
    >>

    i think you are trying to do something like:

    echo "Dont forget to see <a href="http://www.thesims.co.uk/yourphpscript.php3?page=1">TheSims.co.uk</a>";

    //use '" slash for escaping from '"' quotes.


    post your edc.php3 code here .then only we can tell you what is the error you are getting in your script.

    Good Luck!!!



    ------------------
    SR -
    webshiju.com
    www.jobxyz.com-IT Career Portal
    ezipindia.com--WebStudio


    "The fear of the LORD is the beginning of knowledge..."

    [This message has been edited by Shiju Rajan (edited August 13, 2000).]
  10. #6
  11. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    Comber, Belfast, United Kingdom
    Posts
    17
    Rep Power
    0
    Thanks a lot!! so if you want to put a $ or a " you just put / before it. YOu guys are so helpful!

    ------------------
  12. #7
  13. chown python:users\ /world
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Location
    Texas Tech
    Posts
    95
    Rep Power
    15
    No a

    ------------------
    Hartmann
  14. #8
  15. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    Comber, Belfast, United Kingdom
    Posts
    17
    Rep Power
    0
    Sorry iv'e got cantcontrollmyhandsatall syndrom

    ------------------

Similar Threads

  1. httpd.conf and .htaccess confussion
    By pgudge in forum Apache Development
    Replies: 2
    Last Post: August 29th, 2002, 09:55 AM

IMN logo majestic logo threadwatch logo seochat tools logo