Hello Guest

How to get dnymic content on index page?

  • 12 Replies
  • 9501 Views
How to get dnymic content on index page?
« on: October 27, 2013, 10:51:29 AM »
Hey there!

At the moment I'm trying to set up XT-CMS for a test page.
So far I've uploaded themes and added some categories.

However, how to get dynamic content on my index page? The page is gator3069.hostgator.com/~balance

*

xtom

  • *****
  • 184
    • View Profile
    • XT CMS
Re: How to get dnymic content on index page?
« Reply #1 on: October 27, 2013, 04:30:59 PM »
You need to define an area on your page where the dynamic content will be placed. To do this in xara create a placeholder and in the html code body put the special tag {page_content} - If this is for a home page I would recommend calling this page "home" in xara instead of "index" or "default" but make sure you also have page named default. The default page should usually be a bare/generic page template whereas a home page template would usually have home page specific elements on it.

Then when you publish all this from xara back into the cms the cms will then know where to put the dynamic content on that particular page template when it is used with a category. If it's the home page you're working on modify category 0 in the cms and put your editable content in the main content area and make sure to select the page template that you added the dynamic placeholder to which would be called "home" if you named it so.

Bear in mind you should be logged into the cms as admin when you are uploading new page templates so the cms can import/update them automatically.

Have a look at this video which explains editing page templates in xara -> http://www.youtube.com/watch?v=6T4E-QxDcPQ
« Last Edit: October 27, 2013, 04:32:39 PM by xtom »

Re: How to get dnymic content on index page?
« Reply #2 on: October 27, 2013, 05:28:08 PM »
So far I've watched every tutorial ;)

I don't get it working :/ atm it says "{page_content}" on the index page.
I put the index.php file outside the cms directory, don't know why...

So what to do to edit the content of the main page?

ps.: xt-cms seems to be down, how long will the maintenance take?
« Last Edit: October 27, 2013, 05:35:29 PM by n90media »

*

xtom

  • *****
  • 184
    • View Profile
    • XT CMS
Re: How to get dnymic content on index page?
« Reply #3 on: October 27, 2013, 06:15:56 PM »
First make sure you upload your page templates from xara into a theme folder in the cms and not into the root directory for your website. If you haven't already create a new folder eg. cms/themes/mytheme and in xara make sure your publish settings are set to publish into this new theme directory. Then in the admin area of the cms go to configuration and select this new theme.

Once you've done that, in the root directory of your website you should have an index.php file that points to cms_front.php

This index.php in your website root directory should only have the code below...

Code: [Select]
<?php require_once("cms/scripts/cms_front.php"?>
Have a look at Step 4 in the install guide for more info http://www.xt-cms.com/downloads/XT-CMS%20Install%20Guide.pdf

Also make sure there are no existing index.htm or index.html files in your websites root directory because these are usually given preference and the index.php could be ignored.

The xt-cms site should be up and running again now.

Re: How to get dnymic content on index page?
« Reply #4 on: October 27, 2013, 06:19:21 PM »
thanks!

The license file has to be replaced with the old trial license file, right?
Because I still see the "trial mode" warning.

I set my template folder to a directory in themes calles "theme4". Does it matter how the htm file is called?
« Last Edit: October 27, 2013, 06:29:31 PM by n90media »

*

xtom

  • *****
  • 184
    • View Profile
    • XT CMS
Re: How to get dnymic content on index page?
« Reply #5 on: October 27, 2013, 06:32:39 PM »
Yes, but only change it when you are running the cms on the domain that the licence covers. A domain license file will only work with the domain name it's intended for so you'll need to use this when you are running the cms on that actual domain. If you're testing on a different domain you'll need to use the trial license as it works on any domain.

Re: How to get dnymic content on index page?
« Reply #6 on: October 27, 2013, 06:38:07 PM »
So I will not be able to set up my page properly until I have transferred?

I'm also getting an error message on my main site right now: http://gator3069.hostgator.com/~balance/
help appreciated :)
thanks!

*

xtom

  • *****
  • 184
    • View Profile
    • XT CMS
Re: How to get dnymic content on index page?
« Reply #7 on: October 27, 2013, 06:51:19 PM »
Quote
I set my template folder to a directory in themes calles "theme4". Does it matter how the htm file is called?

So your page template files should be uploaded from xara into your theme4 directory and these can be .htm or .php extension - so for example you might have default.htm - home.htm - otherpage.htm etc. again you should always have a default.htm or default.php file in there. I think Xara exports them with .htm extension.

Quote
So I will not be able to set up my page properly until I have transferred?
You should be able to get the guts of a site up and running with the trial license and then add the additional pages and content etc. when you go live on the licensed domain. If wanted to run the full version of the cms on a test domain you would need a separate license for that particular domain. 

Quote
I'm also getting an error message on my main site right now: http://gator3069.hostgator.com/~balance/

It looks like you haven't switched to your new theme, it's showing the default theme. Go to admin -> configuration in the cms and make sure the theme is set to theme4

Re: How to get dnymic content on index page?
« Reply #8 on: October 27, 2013, 07:43:04 PM »
thanks for the answers!

I checked it, theme4 is selected?
I uploaded a default.htm file, the site is online now.
However, it seems as if there is no difference if I choose the default template or the home template, it always shows up the default template. No dynamic content is displayed :/
sorry for bombarding you with questions ;)

*

xtom

  • *****
  • 184
    • View Profile
    • XT CMS
Re: How to get dnymic content on index page?
« Reply #9 on: October 28, 2013, 11:29:42 AM »
Quote
it seems as if there is no difference if I choose the default template or the home template, it always shows up the default template.

The only way I could think this would happen is if both page templates were the same. For example if in xara you duplicated the home page and renamed the copied page to default. Then you would have two page templates that exactly the same. Make sure the pages are actually different in xara. If you want to pm me an admin login I'll have a look and get a better idea of what is going on.

Quote
No dynamic content is displayed

If you modify the home page category and add some text into the main content area it should show up now. Make sure you're modifying category 0 which is the home page category.

Also as you are running the the cms from your website root you will want to update the cms url and website url in admin -> configuration and set them to http://gator3069.hostgator.com/~balance/ - looking at the source code it looks like these are currently set to http://gator3069.hostgator.com/~balance/cms/


Re: How to get dnymic content on index page?
« Reply #10 on: October 28, 2013, 12:20:05 PM »
The page templates should be different ones :/
If you don't mind I will pm you the admin login... so sorry for making such a fuss

*

xtom

  • *****
  • 184
    • View Profile
    • XT CMS
Re: How to get dnymic content on index page?
« Reply #11 on: October 28, 2013, 01:07:55 PM »
The dynamic content should be displaying now and it looks like changing the page templates is working aswell. It was the recent url fix I did for you that was causing this problem. So I've basically updated the rest of the cms files in your install so they are now all from the same version and working properly together.

Re: How to get dnymic content on index page?
« Reply #12 on: October 28, 2013, 01:14:02 PM »
great :)!!! Thank you so much!