Convert Wordpress Template to CMSMS

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Convert Wordpress Template to CMSMS

Post by slloyd »

Anyone out there up for converting a WP template to cmsms for me? If so, please state your fee.
Cobby
Forum Members
Forum Members
Posts: 23
Joined: Sun Jun 17, 2007 5:15 am

Re: Convert Wordpress Template to CMSMS

Post by Cobby »

It would be relatively easy to do it yourself. As long as you can get the stylesheets and HTML from WordPress.

Have a watch of this video to learn how to import ANY type of template into CMSMS
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

There's a lot of php code in there, so I'm not sure what needs to be removed and what should stay. I took a crack at it and it was a mess. I especially have difficulty getting the menu correct.

If the video includes instructions for WP templates, send the link my way and I'll take a look.
Cobby
Forum Members
Forum Members
Posts: 23
Joined: Sun Jun 17, 2007 5:15 am

Re: Convert Wordpress Template to CMSMS

Post by Cobby »

Sorry, forgot to post the link to the video. It doesn't have anything specific to wordpress, but any template, regardless of whether or not it came from another CMS.

Heres this link -> http://cmsmadesimple.org/uploads/media/ ... colate.htm
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

Thanks. Well, I tried it and this is what I got:

http://testsite.preschoolrock.com/index.php/test-page1

and this is what I'm shooting for:

http://preschoolrockmoms.com/

Can you help?
Cobby
Forum Members
Forum Members
Posts: 23
Joined: Sun Jun 17, 2007 5:15 am

Re: Convert Wordpress Template to CMSMS

Post by Cobby »

Its close....
With the original site, view the page source. Copy that into a new template on CMSMS. Then change this:

Code: Select all

<__html>
<head>
<title>Preschool Rock Moms</title>
.....
<meta name="description" content="Preschool Rock Moms is a radio show for moms of preschoolers. Anything and everything related to the parenting of preschoolers is discussed in the radio show. Special guests appear on most Preschool Rock Moms shows. Get a complete listing of Preschool Rock Moms radio shows." />
<meta name="keywords" content="preschool rock moms, radio shows, parents, moms, parenting, radio shows for moms, shows for parents, podcasts for parents, podcasts for moms, radio shows for parents, preschool rock, podcasts, listen, live, shows " />

....
<link rel="stylesheet" href="http://preschoolrockmoms.com/wp-content/plugins/dd-formmailer/dd-formmailer.css" type="text/css" media="screen" />
....
</head>
</__body>
<__body>
</__html>
To:

Code: Select all

<__html>
<head>
<title>{title}</title>
.....
{metadata}
.....
{stylesheet}
....
</head>
</__body>
<__body>
</__html>
That will change the stylesheet and meta tags.

Now for the content, change:

Code: Select all

<__html>
<head>
<title>{title}</title>
.....
{metadata}
.....
{stylesheet}
....
</head>
</__body>
......
<div class="post" id="post-31">
				<div class="box_title">
					<div class="left"><a href="http://preschoolrockmoms.com/shows/perfect-sitter/#respond" title="Comment on Parenting Tips: Finding the Perfect Sitter">0</a></div>
					<div class="right">

					<h2><a href="http://preschoolrockmoms.com/shows/perfect-sitter/" rel="bookmark" title="Permanent Link to Parenting Tips: Finding the Perfect Sitter">Parenting Tips: Finding the Perfect Sitter</a></h2>
								<small>Posted: June 3rd, 2007<br />
		Category: <a href="http://preschoolrockmoms.com/category/shows/" title="View all posts in All Shows" rel="category tag">All Shows</a>,  <a href="http://preschoolrockmoms.com/category/shows/tips/" title="View all posts in Parenting Tips" rel="category tag">Parenting Tips</a> | 					</small>
					</div>
					<br class="clear" />

				</div>
				
				<div class="entry">
					<p>Show Date: <strong>Sunday, June 24, 2007 @ 4pm PST / 7pm EST</strong><br />
Guest Appearance: <strong>Genevieve Thiers, Founder and CEO of </strong><a href="http://www.sittercity.com/"><strong>www.SitterCity.com</strong></a> <br />
Finding a sitter for your preschooler is not only a challenge, but it can be stressful, too. What should you look for in a sitter? How can you get a background check on a sitter? Where can you find a selection of sitters? What questions should you ask a potential sitter? If you’re seeking a sitter and you’re not sure how to go about finding the perfect sitter for your family, tune in for some great tips from Genevieve Theirs.<br />

 <a href="http://preschoolrockmoms.com/shows/perfect-sitter/#more-31" class="more-link">More »</a></p>
				</div>
		
				<p class="edit"></p>
			</div>
...
.include all the posts on the page (all tech on the left side column)
....

<__body>
</__html>
To:

Code: Select all

<__html>
<head>
<title>{title}</title>
....
{metadata}
....
{stylesheet}
....
</head>
</__body>
......
{content}
......
<__body>
</__html>
And that should be the template finished. But you now need to change the news article template. Heres the summary template:

Code: Select all

<!-- Start News Display Template -->
{foreach from=$items item=entry}
<div class="NewsSummary">

<div class="left">
	<a href="{$entry->link}/#respond">{$entry->title}</a>
</div>
<div class="right">
<h2>{$entry->titlelink}</h2>
<small>
{if $entry->formatpostdate}
		{$entry->formatpostdate}
{/if}
<br />
	{$category_label} {$entry->category}
{/if}</small>
</div>
<br class="clear" />
{if $entry->author}
	<div class="NewsSummaryAuthor">
		{$author_label} {$entry->author}
	</div>
{/if}

{if $entry->summary}
	<div class="entry">
		{eval var=$entry->summary}
	</div>

	<p align="right"><div class="NewsSummaryMorelink">
		[{$entry->morelink}]
	</div>
{if $entry->formatpostdate}
	<div class="NewsSummaryPostdate">
		{$entry->formatpostdate}
	</div></p>
{/if}

{else if $entry->content}

	<div class="NewsSummaryContent">
		{eval var=$entry->content}
	</div>
{/if}

</div>
{/foreach}
<!-- End News Display Template -->
That should be something along the lines of the news summary. I'm really sorry, be I don't have time to convert the Detail template, but that should get you started.

Chhers,
Cobby
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

Thanks for the help!

The only things I'm having difficulty with now is:

1. getting rid of the index.php (I think I read something about that somewhere)
2. I can't figure out why the menu for the page I'm on doesn't display. For example, when I'm on the home page, the word "Home" doesn't display in the menu.
3. Is there a way to get the expanded version of the News post to display on a different template/page?
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am
Location: Arizona

Re: Convert Wordpress Template to CMSMS

Post by Dr.CSS »

1) This is set in the config.php and can be found in the Users Handbook under Documentation tab above...

2) You may need to tweak the menu template...the {menu} tag you used is calling the current page by a diff. class than your CSS, .currentpage as apposed to...
#header_top li.current_page_item a {
background:#bdcf63; 

and it is putting a h3 tag w/o a href=....  Current page is 1: Home

You need to attach the crossbrowser CSS to this template to get rid of the dfn numbers and words....

3) The News as all modules has a Help section that has the parameters such as  detailpage="some page alias"  go to Extensions > Modules and click the module name or Help on the right to access it...
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

Thanks so much, Mark! You're always so helpful!

I got everything to work, but I noticed I'm getting an "error" down at the bottom of the page in the browser bar. Any ideas?

It reads, "Line 21, Char 1, Object Expected, Code 0"
Last edited by slloyd on Sat Jun 23, 2007 3:46 pm, edited 1 time in total.
cyberman

Re: Convert Wordpress Template to CMSMS

Post by cyberman »

slloyd wrote:
2) You may need to tweak the menu template...
Menu template? I don't have a menu template; I just have the page's template and the CSS
I'm sure you have a menu template  ;D - if not you cant see a menu. The file simple_navigation.tpl is used by default. And if you wanna modify it you can import it to database.
You need to attach the crossbrowser CSS to this template to get rid of the dfn numbers and words....
Crossbrowser CSS? Where is that?
Also with default install comes a stylesheet named "Accessibility and cross browser tools". This one you have to attach to your template.
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

Oops, I edited my post while you were posting!

I ended up importing the horizontal menu template and adjusting the menu code. That seemed to work.

Do I still need the Accessibility and cross browser tools stylesheet? It makes my horizontal line disappear.

I can't figure out how to fix that erro message I'm getting (see previous post).
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

I fixed it! yay!

Do I still need the Accessibility and cross browser...?

Thanks to everyone for all your help!
cyberman

Re: Convert Wordpress Template to CMSMS

Post by cyberman »

slloyd wrote: It makes my horizontal line disappear.
Yeah, cause this line has the class "accessibility" so it's not shown on page but for screen readers.

If you dont like it remove class ...
slloyd
Forum Members
Forum Members
Posts: 195
Joined: Mon Apr 24, 2006 9:09 pm

Re: Convert Wordpress Template to CMSMS

Post by slloyd »

Thanks. I got it now! you guys are great! ;)
Post Reply

Return to “Developers Discussion”