thank you for the help.

i wil keep trying to get it working.

Michael Sullivan wrote:
> On Tue, 2006-03-21 at 00:52 +0000, Mark Mckee wrote:
> 
>>hi all
>>
>>i want to create an inut page for the content on my website. is it 
>>possible to have 1 data entry box and choose the specific what table
>>of 
>>a database to put it usign a drop down box?
>>
>>if so, can someone please point me in the right direction. i have
>>been 
>>troubling over this for the last few days
>>
>>thanks in adavce
>>
>>mark m...
> 
> 
> I don't see why this wouldn't be possible.  You would just use the table
> name selected from the list box in constructing the query string you use
> in your mysql_query.
> 
> Ex.
> 
> I select 'SomeTable' from a list box called 'list' and hit the Submit
> button.  Another page is called, in which is a line like this:
> 
> $list = $_POST['list'];
> 
> 
> 
> You code says:
> 
> $query = "SELECT * FROM ".$list;
> 
> Then you issue 
> 
> $result = mysql_query($query, $link2DB) or die ("Could not access table
> $list:".mysql_error());
> 
> or whatever you want... 
> 
> 
> 
> 
> 
> Community email addresses:
>   Post message: php-list@yahoogroups.com
>   Subscribe:    [EMAIL PROTECTED]
>   Unsubscribe:  [EMAIL PROTECTED]
>   List owner:   [EMAIL PROTECTED]
> 
> Shortcut URL to this page:
>   http://groups.yahoo.com/group/php-list 
> Yahoo! Groups Links
> 
> 
> 
>  
> 
> 
> 
> 


Community email addresses:
  Post message: php-list@yahoogroups.com
  Subscribe:    [EMAIL PROTECTED]
  Unsubscribe:  [EMAIL PROTECTED]
  List owner:   [EMAIL PROTECTED]

Shortcut URL to this page:
  http://groups.yahoo.com/group/php-list 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/php-list/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to