This is a discussion on "Why is this not working!" within the PHP Forum section. This forum, and the thread "Why is this not working! are both part of the Program Your Website category.
|
|
|
|
|
![]() |
||
Why is this not working!
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
||||
|
||||
|
Why is this not working!
Ok, sort of related to my other thread but just a simple problem. Take this class:
On the home page:
The error MySQL gives (added error report thingy) is: Quote:
__________________
Jack Franklin - Webforumz Moderator (x)HTML | CSS | PHP | MySQL | JQuery (Javascript) Contact: My Blog | Twitter | Delicious Want Lessons? PM me. If you think I've helped, please press the 'Thanks' Button.
Last Blog Entry: A Week with VBulletin (Aug 28th, 2008)
Last edited by Jack Franklin; Mar 24th, 2008 at 18:47. |
|
|
|
#2
|
||||
|
||||
|
Re: Why is this not working!
Try this as your SQL query:
__________________
Web Design And Development: Other Road Design | Problems with IE6?: KApp | My Blog: Only Nerds Allowed | Learning PHP? Lessons
Last Blog Entry: Hilarious Rapper (Jul 29th, 2008)
|
|
#3
|
||||
|
||||
|
Re: Why is this not working!
Nope, error. Wrong table name.
__________________
Jack Franklin - Webforumz Moderator (x)HTML | CSS | PHP | MySQL | JQuery (Javascript) Contact: My Blog | Twitter | Delicious Want Lessons? PM me. If you think I've helped, please press the 'Thanks' Button.
Last Blog Entry: A Week with VBulletin (Aug 28th, 2008)
|
|
#4
|
||||
|
||||
|
Re: Why is this not working!
Hmmmm..... What's the query that the PHP is generating?
__________________
Web Design And Development: Other Road Design | Problems with IE6?: KApp | My Blog: Only Nerds Allowed | Learning PHP? Lessons
Last Blog Entry: Hilarious Rapper (Jul 29th, 2008)
|
|
#5
|
|||
|
|||
|
Re: Why is this not working!
i think is just due to the quotes; try removing them :
'$table' -> $table |
|
#6
|
||||
|
||||
|
Re: Why is this not working!
No luck.
Oh well. Don't worry, I've given up anyway, it was getting to complex for me.
__________________
Jack Franklin - Webforumz Moderator (x)HTML | CSS | PHP | MySQL | JQuery (Javascript) Contact: My Blog | Twitter | Delicious Want Lessons? PM me. If you think I've helped, please press the 'Thanks' Button.
Last Blog Entry: A Week with VBulletin (Aug 28th, 2008)
|
|
#7
|
|||
|
|||
|
Re: Why is this not working!
Surely you are not naming the right variable i.e. you have $selector when you should be using $theselector or $this->selector
|This would also seem correct due to the error message as $selector isn't one of the defined variables therefore you will be passing "Select '' from '' " as a query. |
|
#8
|
||||
|
||||
|
Re: Why is this not working!
implrm you are a genius! As are the others! Turned out I had a typo, so aihazm's suggestion was right. The line now looks like:
__________________
Jack Franklin - Webforumz Moderator (x)HTML | CSS | PHP | MySQL | JQuery (Javascript) Contact: My Blog | Twitter | Delicious Want Lessons? PM me. If you think I've helped, please press the 'Thanks' Button.
Last Blog Entry: A Week with VBulletin (Aug 28th, 2008)
|
![]() |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| CSS not working in IE? | Jgag | Web Page Design | 2 | Jun 5th, 2008 11:14 |
| PNG - IE not working | Phixon | Web Page Design | 3 | Nov 30th, 2007 13:47 |
| php not working? | gsquare567 | PHP Forum | 10 | Apr 24th, 2007 18:52 |
| PHP not working | toolmania1 | PHP Forum | 1 | Nov 1st, 2006 05:57 |