Post by mehdi » Wed Dec 19, 2007 9:20 pm

I was trying to change the pars time direction to right ,so i done the following.
1. Add a style in default.css for example:
.parsetime {
text-align:right;
direction:rtl;
}
2.Add class="parstime' to the default.tpl as follow:





but the parse time position doesn't changed.
I realized that if you delete the codes that i noticed in step 2 the parsetime wouldn't change and it will be shown.
because of these code in index.php
// Parse Time
if ($config->get('config_parse_time')) {
      echo($language->get('text_time', round((time() + microtime()) - $time, 4)));
      } 
as you can see parse time is shown du to "echo" command in index.php and not in the default.tpl

Newbie

Posts

Joined
Sat Dec 01, 2007 5:40 am

Post by bruce » Sat Jan 26, 2008 10:39 am

The id selector #time takes precedence. Have a look for #time in default.css and change that instead.

Active Member

Posts

Joined
Wed Dec 12, 2007 2:26 pm

Post by dad » Sat Oct 25, 2008 9:44 pm

This bug is not fixed in the OpenCart v0.7.9 RC3. How I can change output of the parse time?

I can change the parse time output only if I change codes in the /admin/index.php:
// Parse Time
if ($config->get('config_parse_time')) {
echo(''.$language->get('text_time', round((time() + microtime()) - $time, 2))).'';
}

Changes of codes for the parse time in the default.css and in the layout.tpl are not change it.

dad
New member

Posts

Joined
Tue May 27, 2008 4:30 am

Post by Qphoria » Sat Oct 25, 2008 11:12 pm

Yea, actually it does appear to be bugged.

the main index.php has the code at the bottom of the file:

Code: Select all

// Parse Time
if ($config->get('config_parse_time')) {
	echo($language->get('text_time', round((time() + microtime()) - $time, 4)));
}
That code
- has no css class assigned
- it outside the entire structure.
- is bad

The code in catalog/template/default/layout.tpl is:

Code: Select all

<?php if (isset($time)) { ?>
<div id="time"><?php echo $time; ?></div>
<?php } ?>
which does have a class, and is set to display inside the tags
But the conditional will never return true for isset as it is never being passed to the view

Going to move this to the bug reports section

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by Qphoria » Sat Oct 25, 2008 11:23 pm

Please see the bug tracker for further development:
http://code.google.com/p/open-cart/issues/detail?id=89

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by Qphoria » Mon Oct 27, 2008 11:31 pm

Bug tracker updated with some reasoning for its current design. The reasoning is sound, but if anyone has a better idea, we'd love to hear it.

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am
Who is online

Users browsing this forum: No registered users and 2 guests