Forums / Developer / Offsets not working -> Object not available / reported bugs ..

Offsets not working -> Object not available / reported bugs ..

Author Message

Jørgen Skogstad

Saturday 03 May 2003 11:25:17 pm

Kindest ..

It seems that I have run into the same problems as a few other people here. I see there are two reported bugs with respect to offsets;

http://www.ez.no/developer/ez_publish_3/bug_reports/slideshow_or_offset_wont_work_anymore
http://www.ez.no/developer/ez_publish_3/bug_reports/navigator_offset_page_commands_fail_object_not_available

Have anyone actually gotten this to work? I am working with 3.0.2 og Ez .. and this is as "always" an urgent fix.

Any comments from the Ez people?

Kindest,
Jørgen Skogstad

Jørgen Skogstad

Sunday 04 May 2003 6:12:46 am

Just a note .. I just downgraded to v3.0-1 and now the offset thing works. Something must have changed ..

.. anywyas; it seems that the database structure is the same between v3.0-1 and v3.0-2 .. so I will continue with the v3.0-1 for the time being until this bug has been fixed.

Just thought you guys wanted to know!

Sergiy Pushchin

Wednesday 07 May 2003 12:44:30 am

Fixed.
Index: kernel/classes/ezcontentobject.php
===================================================================
--- kernel/classes/ezcontentobject.php (revision 2412)
+++ kernel/classes/ezcontentobject.php (working copy)
@@ -1680,7 +1680,7 @@
include_once( 'kernel/classes/datatypes/ezuser/ezuser.php' );
include_once( 'kernel/classes/ezuserdiscountrule.php' );
$user =& eZUser::currentUser();
- $languageCode = $Params['LanguageCode'];
+ $languageCode = $Params['Language'];
$language = $languageCode;
if ( $language == '' )
$language = eZContentObject::defaultLanguage();
Index: kernel/content/view.php
===================================================================
--- kernel/content/view.php (revision 2412)
+++ kernel/content/view.php (working copy)
@@ -48,7 +48,7 @@
$ViewMode = $Params['ViewMode'];
$NodeID = $Params['NodeID'];
$Module =& $Params['Module'];
-$LanguageCode = $Params['LanguageCode'];
+$LanguageCode = $Params['Language'];
$Offset = $Params['Offset'];

if ( !is_numeric( $Offset ) )
Index: kernel/content/module.php
===================================================================
--- kernel/content/module.php (revision 2412)
+++ kernel/content/module.php (working copy)
@@ -75,7 +75,7 @@
"functions" => array( 'read' ),
"default_navigation_part" => 'ezcontentnavigationpart',
"script" => "view.php",
- "params" => array( "ViewMode", "NodeID", "LanguageCode" ),
+ "params" => array( "ViewMode", "NodeID" ),
"unordered_params" => array( "language" => "Language",
"offset" => "Offset" )
);

Adolfo Barragán

Thursday 08 May 2003 5:03:55 am

Ok, but...
How can I apply these changes?

Sergiy Pushchin

Friday 09 May 2003 1:15:53 am

Two ways. One is using 'patch' command in unix another is by ha nands.

You need to modify three files:
kernel/classes/ezcontentobject.php
go to line 1680
look for line down and modify the string
$languageCode = $Params['LanguageCode'];
to
$languageCode = $Params['Language'];

If you see in you should just modify line marked with '-' to line marked with '+'

kernel/content/view.php
$LanguageCode = $Params['LanguageCode'];
to
$LanguageCode = $Params['Language'];

kernel/content/module.php
"params" => array( "ViewMode", "NodeID", "LanguageCode" ),
to
"params" => array( "ViewMode", "NodeID" ),

eZ debug

Timing: Jan 30 2025 21:09:20
Script start
Timing: Jan 30 2025 21:09:20
Module start 'content'
Timing: Jan 30 2025 21:09:20
Module end 'content'
Timing: Jan 30 2025 21:09:20
Script end

Main resources:

Total runtime0.2330 sec
Peak memory usage8,192.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0085 588.1563370.2734
Module start 'content' 0.00850.0136 958.42971,005.6094
Module end 'content' 0.02210.2109 1,964.03913,894.3359
Script end 0.2330  5,858.3750 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00441.8721200.0002
Check MTime0.00130.5677200.0001
Mysql Total
Database connection0.00090.402110.0009
Mysqli_queries0.142461.11081410.0010
Looping result0.00120.53001390.0000
Template Total0.210490.310.2104
Template load0.00080.344610.0008
Template processing0.209689.955910.2096
Override
Cache load0.00060.237710.0006
Sytem overhead
Fetch class attribute can translate value0.00170.708910.0017
XML
Image XML parsing0.00020.106410.0002
General
dbfile0.00843.6069200.0004
String conversion0.00000.002730.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs