SitePoint Sponsor

User Tag List

Results 1 to 10 of 10
  1. #1
    SitePoint Wizard edshuck's Avatar
    Join Date
    Jul 2000
    Posts
    1,200
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    question about the signup.php

    hi

    i am trying to use the signup.php and the accesscontrol.php that are shown in the tutorial by kevin.

    i have worked through the problems that i had with the accesscontrol.php but am still having a problem with the signup.php The problem is here.

    <?php
    else:
    //process signup submission
    dbConnect('edshuck');

    and brings in the following:

    Parse error: parse error in /home/edshuck/public_html/parks/signup.php4 on line 69

    line 69 is the else: and edshuck is name of the db.

    any ideas as to where i went wrong?

  2. #2
    SitePoint Guru
    Join Date
    Apr 2001
    Location
    BC, Canada
    Posts
    630
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    and else statement usually looks like

    if (statement)
    {
    //do stuff
    }
    else
    {
    //do other stuff
    }

    I think your missing the '}' and '{' parathesis (spelling?)

  3. #3
    SitePoint Wizard edshuck's Avatar
    Join Date
    Jul 2000
    Posts
    1,200
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi

    thanks for looking.

    another spot where the same thing occurs is in the editauthor.php in the older kevin yank tutorial.

    <?php

    ekse: //Allow the user to edit the author
    //with ID=$id

    $author= and so on.

    I will keep after it. I know from the php/mysql tutorial that it has to be me making an error.

    later and thanks again.

    ed

  4. #4
    SitePoint Guru
    Join Date
    Apr 2001
    Location
    BC, Canada
    Posts
    630
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    sorry, Im not really sure what u are trying to say

  5. #5
    SitePoint Wizard edshuck's Avatar
    Join Date
    Jul 2000
    Posts
    1,200
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi

    i am sorry also, bit confused.

    i may have stumbled onto another set of self abusive problems that i have created.

    i have created a file called admin.inc way back when kevin was working with us to get the mysql/php kick started and i put that in a directory outside the public_html.

    now i built the db.php and called it db.inc and put it in the same dir.

    since the two do not work the same and both access the db. one can be active into the db and trying to use the other does not work.

    i think this is part of the problem, if not then it may be a whole set of problems waiting to happen.

    thanks for all the help and i will look at the problem, make it work and post the findings.

    peace

  6. #6
    SitePoint Guru
    Join Date
    Apr 2001
    Location
    BC, Canada
    Posts
    630
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hmmm..
    still not sure what u are trying to say
    are u saying that when one page is connected to the database, the otehr one isnt it? if thats the case,u may have to contact your server cuz something is messed up


    also I noticed that u named your files with .inc extension, these are usualy used for includes. is that what you are using them for? I dont think php will compile a file withough a php extension

  7. #7
    SitePoint Evangelist =X='s Avatar
    Join Date
    Jun 2001
    Posts
    487
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    slighltywhacked, you are a bit wrong here, there are more ways to do and if statement.
    the other looks like this:

    if(x>0):
    //some code

    else:
    //some other code

    endif;

    It's useful if you put a lot of html code inbetween, so you don't mistake with { these...

  8. #8
    SitePoint Guru
    Join Date
    Apr 2001
    Location
    BC, Canada
    Posts
    630
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thanx
    sorry about that
    guess u learn something new everyday

  9. #9
    SitePoint Wizard edshuck's Avatar
    Join Date
    Jul 2000
    Posts
    1,200
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi

    still looking for the answer. back when i find it.

  10. #10
    SitePoint Wizard johnn's Avatar
    Join Date
    Mar 2001
    Location
    Southern California, USA
    Posts
    1,181
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi,
    You should remove the colon at "else:", I think.

    John


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •