Author Topic: Small mod for adding sub pages  (Read 1575 times)

Offline noname8

  • Posts: 141
Small mod for adding sub pages
« on: November 16, 2010, 03:19:42 PM »
So If you have wb 2.8 and huge site it's pain for adding 20 psc of sub pages under same page.


To make it easier I've added small link + session variable. Of course there is the green + sign on the right but this saves time even more.

admin/pages/add.php
Code: [Select]
//line 43
$_SESSION['lastaddparentpage']=$parent;

admin/pages/index.php

Code: [Select]
//line 570
$latestaddhacktxt='';
if($_SESSION['lastaddparentpage'] >1) $latestaddhacktxt='(Same)';
// Insert language text and messages
//...
//...
//...
//line 589 add 1 more line:
'INTRO_LINK' => $MESSAGE['PAGES']['INTRO_LINK'],
'LATESTADDHACK' => '<a href="#" onclick="add_child_page('.$_SESSION[lastaddparentpage].');return false;" title="Click to set to latest">'.$latestaddhacktxt.'</a>'

and templates\wb_theme\templates\pages.htt:

Code: [Select]
// find {TEXT_PARENT}: and convert the line to
  <td width="70">{TEXT_PARENT}: {LATESTADDHACK}</td>



Any suggestions are welcome

 

postern-length