Project

General

Profile

Bug #18419 ยป 7816_newpage_no_id.diff

Administrator Admin, 2008-03-10 20:21

View differences:

typo3/alt_db_navframe.php (working copy)
);
// New Page
$onclickNewPageWizard = 'top.content.list_frame.location.href=top.TS.PATH_typo3+\'db_new.php?id=1&pagesOnly=1\';"';
$onclickNewPageWizard = 'top.content.list_frame.location.href=top.TS.PATH_typo3+\'db_new.php?pagesOnly=1&id=\'+Tree.pageID;"';
$buttons['new_page'] = '<a href="#" onclick="' . $onclickNewPageWizard . '"><img' . t3lib_iconWorks::skinImg('', 'gfx/new_page.gif') . ' title="' . $LANG->sL('LLL:EXT:cms/layout/locallang.xml:newPage', 1) . '" alt="" /></a>';
// Refresh
typo3/js/tree.js (working copy)
frameSetModule: null,
activateDragDrop: true,
highlightClass: 'active',
pageID: 0,
// reloads a part of the page tree (useful when "expand" / "collapse")
load: function(params, isExpand, obj) {
// fallback if AJAX is not possible (e.g. IE < 6)
......
// selects the activated item again, in case it collapsed and got expanded again
reSelectActiveItem: function() {
obj = $(top.fsMod.navFrameHighlightedID[this.frameSetModule]);
if (obj) Element.addClassName(obj, this.highlightClass);
if (obj) {
Element.addClassName(obj, this.highlightClass);
this.getPageID(obj.id);
}
},
// highlights an active list item in the page tree and registers it to the top-frame
// used when loading the page for the first time
highlightActiveItem: function(frameSetModule, highlightID) {
this.frameSetModule = frameSetModule;
this.getPageID(highlightID);
// Remove all items that are already highlighted
obj = $(top.fsMod.navFrameHighlightedID[frameSetModule]);
if (obj) {
......
// Set the new item
top.fsMod.navFrameHighlightedID[frameSetModule] = highlightID;
if ($(highlightID)) Element.addClassName(highlightID, this.highlightClass);
},
getPageID: function(highlightID) {
if(highlightID) {
var tmp = highlightID.split('_')[0].substring(5);
this.pageID = tmp;
}
}
};
    (1-1/1)