vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Form woes... (https://vborg.vbsupport.ru/showthread.php?t=57349)

gengar003 09-24-2003 01:51 AM

Form woes...
 
Okay, I've got this code:

PHP Code:

$tid=$HTTP_GET_VARS['tid'];
$templates=$DB_site->query_first("SELECT templateid,title,template FROM template WHERE templateid=$tid");
$title=$templates['title'];
$contents=$templates['template'];
$contents2=htmlspecialchars($contents);;

echo 
"<font size=\"5\">";
echo 
"Editing Template: ";
echo 
$title;
echo 
"</font><p><hr>";
echo 
"<form action=\"edittemplate.php\" method=\"GET\">";
echo 
"<input type=\"hidden\" name=\"action\" value=\"editing\">";
echo 
"<input type=\"hidden\" name=\"title\" value=\"$title\">";
echo 
"<input type=\"hidden\" name=\"templateid\" value=\"$tid\">";
echo 
"<textarea name=\"template\" rows=\"23\" cols=\"53\">";
echo 
$contents2;
echo 
"</textarea><p>";
echo 
"<input type=\"submit\" value=\"Submit!\" name=\"submit\">";
echo 
"</form>"

Which creates an editing form for a given template.
It works for simple templates, like the errormessages, but not on complicated ones, most notably showthread.

What can I do to make it work for showthread and other "complicated" templates?

Why? I need this for after shcool... And I leave for the bus @ 8:20, and I get on the comp ~ 8:00.

Thanks in advance.

:ermm: :ermm: Vb3 gives me too much information.

SmEdD 09-24-2003 02:51 AM

Probley because showthread is template that calls more then one template. The error template uses phrases now so it is only one template.

If I had time I'd fix your code but I got to get to bed ;)

gengar003 09-24-2003 11:56 AM

*hopes that SMED can fix it soon*


All times are GMT. The time now is 08:41 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.01169 seconds
  • Memory Usage 1,715KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete