I created a small article with a small form. and I get this error.
Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/dfbarrac/public_html/Sources/TPSubs.php(3487) : eval()'d code on line 10
here's my PHP code.
echo '<center><form action="' . $scripturl . '?page=' . $_GET['page'] . '" method="post">';
echo '<INPUT id="submitted" name="submitted" type="hidden" value="TRUE" />';
echo '<input id='name' name='name' type='textbox' value='' />';
echo '<input id='email' name='email' type='textbox' value='' />';
echo '<INPUT type="submit" value="Submit">';
echo '<INPUT type="reset" value="Reset">';
echo '</center></form>';
exit;
The only thing I can get it work is some thing like this
echo '
<h3>Hello World</h3>
';
I haven't been able to get any thing else to work. PLEASE help
I think lines three and four should have double quotes around name, e-mail and textbox. And after value.
I fixed that and I still have the same error
Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/dfbarrac/public_html/Sources/TPSubs.php(3487) : eval()'d code on line 10
my code is below.
echo '<center><form action="page.php?page="1" method="post">';
echo '<INPUT id="submitted" name="submitted" type="hidden" value="TRUE" />';
echo '<input id='name' name="name" type="textbox" />';
echo '<input id='email' name="email" type="textbox" />';
echo '<INPUT type="submit" value="Submit">';
echo '<INPUT type="reset" value="Reset">';
echo '</center></form>';
exit;
Well I got the form fixed. It's just that it's real picky. any way I took a sample from the page I got and well it doesn't work. Guys, I'm sorry. Addingthis crap should not be all this hard. I know PHP coding, Just not this kind.
I only made 2 changes to it. and the error is
Fatal error: Function name must be a string in /home/dfbarrac/public_html/Sources/TPSubs.php(3487) : eval()'d code on line 38
and my code is below.
$columns = array(
array(
'name' => 'id',
'type' => 'int',
'size' => 10,
'unsigned' => true,
'auto' => true,
),
array(
'name' => 'name',
'type' => 'tinytext',
),
);
$indexes = array(
array(
'type' => 'primary',
'columns' => array('id')
),
);
$smcFunc['db_create_table']('{db_prefix}db_data', $columns, $indexes, array(), 'update_remove');
I was hoping some one would have some ideas on this.
You're using $smcFunc['db_create_table'] which I think is only available to packages.
db_extend('packages'); is what pulls in the extra db functions like db_create_table. You can read more about those things here:
http://simplemachines.org/community/?topic=224166.0
Cool, Thanks, I'm reading threw it now.