Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Programming Discussions
Prev Previous Post   Next Post Next
  #9  
Old 08-27-2002, 03:42 PM
Vinney Vinney is offline
 
Join Date: Nov 2001
Posts: 68
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cheers NDLR .....but i cant get it to work, i get this error :

Database error in vBulletin 2.2.6:

Invalid SQL: SELECT field5,field9 WHERE userid='1'
mysql error: You have an error in your SQL syntax near 'WHERE userid='1'' at line 1

mysql error number: 1064

Date: Tuesday 27th of August 2002 05:49:54 PM
Script: http://www.peugeot-gti.net/files/helpdesk/

where do i place your code in the following ? :-

PHP Code:
<?php
<?php
error_reporting
(7);
require (
'../../mainfile.php');
$index 1;
global 
$Pmenu,$breadcrumb;
$Pmenu="";
$breadcrumb="Contact Helpdesk";
$defaultmessage "Dear Helpdesk... \n\n - $bbuserinfo[username]";
$defaultemail "$bbuserinfo[email]";
include(
"header.php");
if (
$bbuserinfo[usergroupid]==||  $bbuserinfo[usergroupid]==|| $bbuserinfo[usergroupid]==|| $bbuserinfo[usergroupid]==11) {
eval(
"dooutput(\"".gettemplate('helpdesk_nologin')."\");"); 
} else {
$customfield=$DB_site->query("SELECT field5,field9 WHERE userid='$bbuserinfo[userid]'");
while (
$field=$DB_site->fetch_array($customfield)) {
     
$field5=$feild[5];
     
$feild9=$field[9];
eval(
"\$usercustomfield = \"".gettemplate('helpdesk')."\";");
}
include(
"footer.php");
}
?>
my helpdesk template contains :

Code:
<table cellpadding="0" cellspacing="0" border="0" bgcolor="#0A293E"  width="95%" align="center"><tr><td>
<table cellpadding="4" cellspacing="1" border="0"  width="100%">
<tr>
<td colspan="2" bgcolor="#336D95" background="https://vborg.vbsupport.ru/images/catagory_backing.gif" align="left"><normalfont color="#000000"><b>
Welcome to PGAC Helpdesk - Follow instructions carefully.</b></normalfont></td>
</tr>
<tr>
<td bgcolor="#13486D" align="left" valign="top">
<p align="center">
<normalfont>Welcome to $bbtitle Helpdesk. </normalfont></p>
<p>
<normalfont>Please take the time to carefully read the following instructions.
This e-mail form has been created, so that forum members can place their questions, or 
queries to a member of our help desk.
Please make sure you fill in all the mandatory fields in.<br><br>
If you have recently just joined the club and have received you membership 
number and renewal date via the post, make sure you have placed them details 
within your
<a target="_blank" href="http://www.peugeot-gti.net/forums/member.php?s=$session[sessionhash]&action=editprofile">
UserCP</a> (<a target="_blank" href="http://www.peugeot-gti.net/forums/member.php?s=$session[sessionhash]&action=editprofile">User Control Panel</a>), and then continue with this.<br>
<br>
-$bbtitle Staff</normalfont></td>
</tr>
</table>
</td></tr></table>
<form enctype="multipart/form-data" action="send.php" name="refer" method="post">
<table cellpadding="0" cellspacing="0" border="0" bgcolor="#0A293E"  width="95%" align="center"><tr><td>
<table cellpadding="4" cellspacing="1" border="0"  width="100%">
<tr>
<td colspan="3" bgcolor="#336D95" background="https://vborg.vbsupport.ru/images/catagory_backing.gif" align="left"><normalfont color="#000000"><b>Contact $bbtitle 
Helpdesk!</b></normalfont></td>
</tr>
<tr>
<td bgcolor="#13486D" align="left" valign="top" nowrap><normalfont>Your 
username:</normalfont></td>
<td bgcolor="#13486D" align="left"><input type="text" name="name" size="30" class="bginput" tabindex="1" value="$bbuserinfo[username]"></td>
<td bgcolor="#13486D" align="left"><b><font color="#FF0000">
*</font></b></td>
</tr>
<tr>
<td bgcolor="#1C5780" align="left" valign="top" nowrap><normalfont>Your email:</normalfont></td>
<td bgcolor="#1C5780" align="left"><input type="text" name="email" size="30" class="bginput" tabindex="1" value="$defaultemail"> </td>
<td bgcolor="#1C5780" align="left"><b>
<font color="#FF0000">*</font></b></td>
</tr>
<tr>
<td bgcolor="#13486D" align="left" valign="top" nowrap><normalfont>Your 
m/ship N</normalfont><normalfont><font face="Times New Roman">?</font></normalfont><normalfont>:</normalfont></td>
<td bgcolor="#13486D" align="left">
<input type="text" name="mem" size="4" class="bginput" tabindex="1" value="$field5"></td>
<td bgcolor="#13486D" align="left"><b><font color="#FF0000">
*</font></b></td>
</tr>
<tr>
<td bgcolor="#1C5780" align="left" valign="top" nowrap><normalfont>Your 
renewal date:</normalfont></td>
<td bgcolor="#1C5780" align="left">
<input type="text" name="expiry" size="8" class="bginput" tabindex="1" value="$field9"> example: 
08/12/02</td>
<td bgcolor="#1C5780" align="left"><b>
<font color="#FF0000">*</font></b></td>
</tr>
<tr>
<td bgcolor="#13486D" align="left" valign="top" nowrap><normalfont>Subject:</normalfont></td>
<td bgcolor="#13486D" align="left">
<normalfont><input type="radio" name="title" value="General Feedback" checked>General Feedback<br>
<input type="radio" name="title" value="Bug Report">Bug Report<br>
<input type="radio" name="title" value="Registration Problem">Registration Problem 
/ Activation request (<b><font color="#FF0000"><u>read above</u></font></b>)<br>
<input type="radio" name="title" value="">Other <input type="text" name="otitle" size="25" class="bginput" tabindex="5">
</normalfont>
</td>
<td bgcolor="#13486D" align="left">
<b><font color="#FF0000">*</font></b></td>
</tr>
<tr>
<td bgcolor="#1C5780" align="left" valign="top" nowrap><normalfont>Your message to us:</normalfont></td>
<td bgcolor="#1C5780" align="left">
<textarea name="message" wrap="virtual" cols="70" rows="15" class="bginput" tabindex="6">$defaultmessage</textarea></td>
<td bgcolor="#1C5780" align="left">
<b><font color="#FF0000">*</font></b></td>
</tr>
</table>
</td></tr></table>
<center>
<b><font color="#FF0000">* </font>= Mandatory field</b><br><br>
<input type="submit" value="Send Email" tabindex="7" accesskey="s" class="bginput"></center>
</form>
Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:31 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04679 seconds
  • Memory Usage 2,711KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (5)bbcode_php
  • (8)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (14)post_thanks_box
  • (14)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (14)post_thanks_postbit_info
  • (14)postbit
  • (14)postbit_onlinestatus
  • (14)postbit_wrapper
  • (1)showthread_list
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_threadedmode.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids_threaded
  • showthread_threaded_construct_link
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete