Update 1.2.8 -> 1.2.9 syntax error

Update 1.2.8 -> 1.2.9 syntax error

Postby yeti on Sun Nov 22, 2009 7:54 am

Hi, thx for LifeType, you are doing a great job! Sorry, my english is really bad, I hope I can explain my Problem!
After upgrading to 1.2.9 I get tis error, when I want do work in the Admin panel, e.g. click "articles", "administration/blogs", ressources, etc.:
Parse error: syntax error, unexpected '(' in xxx/lt/tmp/6/%%FE^FEA^FEA975DF%%menutabs.template.php on line 8

After deleting all files in "tmp" _> same problem.
Hope you can help me,
thank you very much,
yeti
yeti
yeti
 
Posts: 21
Joined: Tue Jul 24, 2007 6:34 am
Location: Austria
LifeType Version: 1.2.9

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby jondaley on Mon Nov 23, 2009 7:13 pm

It sounds like the templates/admin/menutabs.template file was uploaded incorrectly. Try reuploading the files.
jondaley
Lifetype Expert
 
Posts: 6169
Joined: Thu May 20, 2004 6:19 pm
Location: Pittsburgh, PA, USA
LifeType Version: 1.2.11 devel branch

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby yeti on Thu Nov 26, 2009 7:13 am

hi jondaley, thx for your answer.
I have reuploaded the file, same problem. In another try I unzipped the package on the server, same result.
I updated a second LifeType Installation, where I left the "menutabs.template" from version 1.2.8 - same problem.
Because of this error, I can't do anything in the admin Panel! :-(
yeti
yeti
 
Posts: 21
Joined: Tue Jul 24, 2007 6:34 am
Location: Austria
LifeType Version: 1.2.9

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby jondaley on Fri Nov 27, 2009 4:03 pm

Hrm, that's odd. Can you post the first 10 lines of the file that is showing the error (ie. the file in the tmp directory).

Does your menutabs file look like this:
http://devel.lifetype.net/svn/plog/plog ... s.template
jondaley
Lifetype Expert
 
Posts: 6169
Joined: Thu May 20, 2004 6:19 pm
Location: Pittsburgh, PA, USA
LifeType Version: 1.2.11 devel branch

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby yeti on Tue Dec 01, 2009 8:48 am

hi jondaley,

this are the first 10 lines of the file menutabs.template.php in the tmp directory:
---------------------
<?php /* Smarty version 2.6.22, created on 2009-12-01 13:35:59
compiled from ./templates/admin/menutabs.template */ ?>
<ul id="tablist">
<?php $this->assign('options', eval('$_foo = $this->_tpl_vars[\'menu\']; $_foo = $_foo->getOpts($this->_tpl_vars[\'showOpt\']); return $_foo;')); ?>
<?php $_from = $this->_tpl_vars['options']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
foreach ($_from as $this->_tpl_vars['option']):
?>
<?php if (eval('$_foo = $this->_tpl_vars[\'option\']; $_foo = $_foo->getAttribute(\'ignoreTab\'); return $_foo;') != 1 && eval('$_foo = $this->_tpl_vars[\'menu\']; $_foo = $_foo->userCanSee; return $_foo;') ( $this->_tpl_vars['option'] , $this->_tpl_vars['user'] )): ?>
<?php $this->assign('name', eval('$_foo = $this->_tpl_vars[\'option\']; $_foo = $_foo->name; return $_foo;')); ?>
<li <?php if ($this->_tpl_vars['name'] == $this->_tpl_vars['showOpt']): ?> id="tab_active" <?php endif; ?>>
-------------------------------

this is the file menutabs.template:
---------------
<ul id="tablist">
{assign var=options value=$menu->getOpts($showOpt)}
{foreach from=$options item=option}
{if $option->getAttribute("ignoreTab") != 1 && $menu->userCanSee( $option, $user )}
{assign var=name value=$option->name}
<li {if $name==$showOpt} id="tab_active" {/if}>
<a {if $name==$showOpt} id="tab_current" {/if} href="{$option->getAttribute("url")}">{$locale->tr($name)}</a>
</li>
{/if}
{/foreach}
</ul>
---------------

As a quick, of course not good solution, I uploaded an empty menutabs.template. So I don't get the error message, posted below, and I can work in the Admin Panel (without seeing the menutabs).
yeti
yeti
 
Posts: 21
Joined: Tue Jul 24, 2007 6:34 am
Location: Austria
LifeType Version: 1.2.9

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby jondaley on Tue Dec 01, 2009 9:56 am

Your menutabs.template looks identical to mine.
But... your file in the tmp directory is not the same as mine, which is really weird. I'd guess you have some sort of debug option turned on for smarty or something, but LifeType doesn't have any configuration values for that, so unless you edited the smarty files directly, I can't explain that.
My menutabs file doesn't have any references to "foo" at all. We are running the same version of smarty.

I see your other bug report that has the strange apache crash. I am now wondering whether either your lifetype files are corrupted somehow, or if your hosting environment already has smarty installed or something and it is causing a conflict.

Can you go to the admin and click on the file version check? (here's the URL, since your menuing is broken: /admin.php?doFileVersionCheck=Check&op=Versions )

Also, can you make a "test.php" file in your root directory and put:
Code: Select all
<?php phpinfo(); ?>

in it, and then send me the URL?
jondaley
Lifetype Expert
 
Posts: 6169
Joined: Thu May 20, 2004 6:19 pm
Location: Pittsburgh, PA, USA
LifeType Version: 1.2.11 devel branch

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby yeti on Tue Dec 01, 2009 12:08 pm

I did the file version check (language is german):
----------
Die folgenden Dateien enthalten nicht den erwarteten Inhalt:
class/data/textfilter.class.php
templates/admin/menutabs.template
templates/summary/agreement.template
templates/summary/blogslist.template
templates/summary/post.template
templates/summary/footer.template
templates/summary/index.template
templates/summary/header.template
templates/summary/postslist.template
LifeType
Die aktuell installierte Version von LifeType lautet:
lifetype-1.2.9_r6922
------------
All of the listed files I edited directly.
As I wrote, menutabs.template is empty (no code), so the menuing works in the main menu, but I don't see menu Tabs in Sub-Menus (no error message with this "solution").
I didn't any editing in the smarty files directly.
yeti
yeti
 
Posts: 21
Joined: Tue Jul 24, 2007 6:34 am
Location: Austria
LifeType Version: 1.2.9

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby jondaley on Wed Dec 02, 2009 4:14 pm

Hrm. I don't see anything that looks interesting. (including the phpinfo that you sent).

Though it turns out that smarty under php4 is what is causing the "extra" eval statements, so that explains why your compiled menutabs file is different than mine. I wouldn't think that is really causing the problem though.
jondaley
Lifetype Expert
 
Posts: 6169
Joined: Thu May 20, 2004 6:19 pm
Location: Pittsburgh, PA, USA
LifeType Version: 1.2.11 devel branch

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby jondaley on Wed Dec 02, 2009 4:22 pm

Ah - found it. It is a bug between the new version of smarty and php4.

Unfortunately, lifetype 1.2.x doesn't run well on the newest versions of php5 (it definitely works up to 5.2.6, I haven't tested higher than that). If you can upgrade to php5 less than that, you'll be all set.

Another solution would be to grab the class/template/smarty directory from LifeType's 1.2.8 release, and that will be fine too.
jondaley
Lifetype Expert
 
Posts: 6169
Joined: Thu May 20, 2004 6:19 pm
Location: Pittsburgh, PA, USA
LifeType Version: 1.2.11 devel branch

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby yeti on Wed Dec 02, 2009 6:11 pm

Thank you very much, jondaley, you are great!
installation seems to work fine now.
I can't upgrade to php 5.2.6 or less, so I use the class/template/smarty directory from LifeType's 1.2.8 release :)
thx,
yeti
yeti
 
Posts: 21
Joined: Tue Jul 24, 2007 6:34 am
Location: Austria
LifeType Version: 1.2.9

Re: Update 1.2.8 -> 1.2.9 syntax error

Postby jondaley on Wed Feb 17, 2010 4:04 pm

I've verified that the 1.2.8 code fixes this error for those people still running php4.
http://bugs.lifetype.net/view.php?id=1632
jondaley
Lifetype Expert
 
Posts: 6169
Joined: Thu May 20, 2004 6:19 pm
Location: Pittsburgh, PA, USA
LifeType Version: 1.2.11 devel branch


Return to Configuration and Installation

cron