Icy Phoenix

     
 


Tags And Keywordscustom pages, customization

Post new topic  Reply to topic 
Page 2 of 2
Goto page Previous  1, 2
 
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Sorry, but I have just tried on my setup and it is working as expected.

Are you sure you have added the page to "Standard Pages" in CMS?

You need to add the page with the correct filename and then add the blocks from CMS.
 




____________
Luca
SEARCH is the quickest way to get support.
Icy Phoenix ColorizeIt - CustomIcy - HON
 
Mighty GorgonSend private messageSend e-mail to userVisit poster's website  
Back to topPage bottom
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us
 
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Okay I am going through the steps here as I did them and see if I missed anything.

1. created guildrules.php and pasted inside the first code snippet from method 2. modified the name of the .tpl
2. created guildrules.tpl and pasted inside the code snippet from method 2.
3. saved both
4. uploaded via ftp as follows
(root)/guildrules.php
(root)/templates/default/guildrules.tpl
5. checked the page and it generated without error
6. went into cms added the page with this info and submitted.
Name: Guild Rules
Page ID: guildrules
Breadcrumbs: yes
View Permission: ALL
7. then added on block left (Nav Links) on right block did (User Block and Recent)
8. go to page to see if anything changed.

Blocks do not appear.

Checked logs internally and no error.
Checked logs for the server and no error.
Checked permissions of both files versus other files in their respective directories and they match.

Everything else works just fine.
 



 
SilvermanSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
i think i found the reason why doesnt work I think
after few hours of searching my page finaly showed up

where is the problem ... now this is the best part  

MG did a little mistake in his first post for option 2
this is correct
Code: (mypage.php) [Download] [Hide] [Select]
<?php
/**
*
* @package Icy Phoenix
* @version $Id$
* @copyright (c) 2008 Icy Phoenix
* @license http://opensource.org/licenses/GPL-license.php GNU Public License
*
*/

define('IN_ICYPHOENIX', true);
if (!
defined('IP_ROOT_PATH')) define('IP_ROOT_PATH', './');
if (!
defined('PHP_EXT')) define('PHP_EXT', substr(strrchr(__FILE__, '.'), 1));
include(
IP_ROOT_PATH . 'common.' . PHP_EXT);

// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup();
// End session management

$mycontent = '<b>My Fantastic Page</b>';

$template->assign_vars(array(
    
'MYCONTENT' => $mycontent
    
)
);

full_page_generation('mycontent_body.tpl', $lang['MYCONTENT'], '', '');

?>


do you see the difference ?
a little space on first line <?php

can you confirm this Silverman ?
 




____________
We are the phpBBorg. Lower your Crackers. Your phpological and forumological distinctivness will be added to our own. Resistance if futile!
 
LimunSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Checked the file, and even re-copied the file and uploaded, no change.  I am going to reupload IP and see if that fixes it.

[UPDATE 1]IP is uploaded again, and no change.

Something else that is funny and this may help find the overall issue.
My navigation will not show a link to the file either.


[UPDATE 2]Correction, the default site map doesn't add the link but a custom menu block will.
 



 
Edited by Silverman, Tue 27 Aug, 2013 19:47: Update
SilvermanSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
can you be more specific please , i dont understand

does the site show up when you click preview ?

 cms_1377669544_128112

can you post here your guildrules.tpl and guildrules.php here
 




____________
We are the phpBBorg. Lower your Crackers. Your phpological and forumological distinctivness will be added to our own. Resistance if futile!
 
LimunSend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Yes the page shows up but without the blocks as I assigned in the Standard Pages.

guildrules.php exact copy
Code: [Download] [Hide]
  1. <?php 
  2. /** 
  3. * @package Icy Phoenix 
  4. * @version $Id$ 
  5. * @copyright (c) 2008 Icy Phoenix 
  6. * @license http://opensource.org/licenses/GPL-license.php GNU Public License 
  7. */ 
  8.  
  9. define('IN_ICYPHOENIX', true); 
  10. if (!defined('IP_ROOT_PATH')) define('IP_ROOT_PATH', './'); 
  11. if (!defined('PHP_EXT')) define('PHP_EXT', substr(strrchr(__FILE__, '.'), 1)); 
  12. include(IP_ROOT_PATH . 'common.' . PHP_EXT); 
  13.  
  14. // Start session management 
  15. $user->session_begin(); 
  16. $auth->acl($user->data); 
  17. $user->setup(); 
  18. // End session management 
  19.  
  20. $mycontent = '<b>My Fantastic Page</b>'; 
  21.  
  22. $template->assign_vars(array( 
  23.     'MYCONTENT' => $mycontent 
  24.     ) 
  25. ); 
  26.  
  27. full_page_generation('guildrules.tpl', $lang['MYCONTENT'], '', ''); 
  28.  
  29. ?>  


guildrules.tpl exact copy
Code: [Download] [Hide]
  1. <!-- INCLUDE overall_header.tpl --> 
  2. {MYCONTENT} 
  3. <!-- INCLUDE overall_footer.tpl --> 


Edit Site Page
Code: [Download] [Hide] [Select]
Name: Guild Rules
PageID: guildrules
filename: guildrules.php
Page Navigation Block (Breadcrumbs): Off (have tried both)
View Permissions: ALL

 



 
SilvermanSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Ok, I found the error.

I missed in the first version to add the PAGE_ID which is needed to display blocks and allows to use the AUTH system.

If you check again the first post, now the guide should work.

For your records, you need to add this to page top after inclusion of COMMON.PHP:

Code: [Download] [Hide] [Select]
$cms_page['page_id'] = 'guildrules';


After this small edit everything should work without further edits.

Here is the altered code of the file you posted:
Code: [Download] [Hide] [Select]
<?php
/**
*
* @package Icy Phoenix
* @version $Id$
* @copyright (c) 2008 Icy Phoenix
* @license http://opensource.org/licenses/GPL-license.php GNU Public License
*
*/

define('IN_ICYPHOENIX', true);
if (!defined('IP_ROOT_PATH')) define('IP_ROOT_PATH', './');
if (!defined('PHP_EXT')) define('PHP_EXT', substr(strrchr(__FILE__, '.'), 1));
include(IP_ROOT_PATH . 'common.' . PHP_EXT);

$cms_page['page_id'] = 'guildrules';

// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup();
// End session management

$mycontent = '<b>My Fantastic Page</b>';

$template->assign_vars(array(
    'MYCONTENT' => $mycontent
    )
);

full_page_generation('guildrules.tpl', $lang['MYCONTENT'], '', '');

?>

 




____________
Luca
SEARCH is the quickest way to get support.
Icy Phoenix ColorizeIt - CustomIcy - HON
 
Mighty GorgonSend private messageSend e-mail to userVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
That did it thank you everyone blocks are showing and changing just fine.
 



 
SilvermanSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Great!
 




____________
Luca
SEARCH is the quickest way to get support.
Icy Phoenix ColorizeIt - CustomIcy - HON
 
Mighty GorgonSend private messageSend e-mail to userVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
HI All

I recently started playing with IP2.0, i have made a standard page but i would like to know how i address a database outwith IP ( on same server but a seperate database ). Also since upgrading to PHP5.5 and appache 2.4.6, the following line is no longer effective.

include(IP_ROOT_PATH . 'alerts/alertsconfig.'.PHP_EXT);

was fine on PHP5.3 and appache 2.2

Appreciate any guidance as these two problems are giving me a major headache
 



 
AndyGpySend private messageVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
To call another database you would need another config file (myconfig.php) with the connect strings, and then you would need to include other strings(script) that calls and parses the connection data - and how it is to be handled - to what you are writing/doing that you want to keep separate.

Maybe something like this.

myconfig.php

Code: [Download] [Hide] [Select]
$dbhost = 'localhost'; // Database host - usually localhost
$dbuser = ''; // Database User Name
$dbpass = ''; // Database Password
$dbname = ''; // Database Name
$dbpre = 0;



Your Page:

Code: [Download] [Hide] [Select]
include "myconfig.php";
error_reporting(E_ALL);
$server = $dbhost;
$dbuser = $dbuser;
$dbpass = $dbpass;
$dbname = $dbname;

$x = mysql_connect($server,$dbuser,$dbpass) or die(mysql_error());
mysql_select_db($dbname,$x);


No doubt you will also have to address or re-define some CONSTANTS and variables - and then the whole thing will get messier.

There may be an easier way - - - - - - Dunno!
 



 
mortSend private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
AndyGpy wrote: [View Post]
I recently started playing with IP2.0, i have made a standard page but i would like to know how i address a database outwith IP ( on same server but a seperate database ).

What do you mean by "address a database"? Do you need to run SQL on another DB?

AndyGpy wrote: [View Post]
Also since upgrading to PHP5.5 and appache 2.4.6, the following line is no longer effective.

include(IP_ROOT_PATH . 'alerts/alertsconfig.'.PHP_EXT);

was fine on PHP5.3 and appache 2.2

Appreciate any guidance as these two problems are giving me a major headache

What do you mean by "no longer effective"... that is just an inclusion... and it should work even on PHP 5.5!  


Please open 2 specific topics in the General Support section... as they are not linked any more to this topic.
 




____________
Luca
SEARCH is the quickest way to get support.
Icy Phoenix ColorizeIt - CustomIcy - HON
 
Mighty GorgonSend private messageSend e-mail to userVisit poster's website  
Back to topPage bottom
Reply with quote Download Post 
Post Re: CUSTOMIZATION - Create A Custom Page In Icy Phoenix 2.0 
 
Good
 



 
yogeshpajiSend private messageVisit poster's website  
Back to topPage bottom
Post new topic  Reply to topic  Page 2 of 2
Goto page Previous  1, 2


Display posts from previous:    

HideWas this topic useful?

Link this topic
URL
BBCode
HTML




 
Permissions List
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events


  

 

  cron