Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Design Opus: Making media to kindle and communicate Vision
My Virginia-based web design site went online last week— amid the ruckus of several other projects that have been keeping me busy, and a-posting here for help.
Here are some production notes that happen to come to mind right now:
- Pages: Most of the site is driven by one page, and my approach was inspired by Tim Van Damme.
- Grids: I used a sixteen column grid adapted from Nathan Smith’s 960 Grid System for layout, but I didn’t use his CSS.
- Speed: I made several notes about speeding up the site, some of which may be helpful for others running Textpattern.
- Feed: Nathan Smith’s piece about using Feedburner with TXP is still mostly on-target.
- 404: It may be geeky, but I think the 404 error page I created is pretty cool. It grabs words from the
request_uri
and displays them in a search input. (I couldn’t get kml_searchkeywords to work.)
Useful admin plugins:
- asy_jpcache
- cnk_versioning (essential)
- lam_accordion_section
- rah_sitemap
- rss_admin_db_manager, updated (essential)
- rss_article_edit
- smd_tags_admin
- smd_where_used (essential)
Useful client-side plugins
- adi_menu
- cbs_navigation_menu (essential)
- mg_txpversion
- pap_contact_cleaner (essential)
- rah_metas (essential)
- rah_output_section_form (essential)
- rah_replace
- rss_auto_excerpt (essential)
- rvm_if_this_article (essential)
- smd_lib
- smd_slimbox, for portfolio section— coming soon (essential)
- smd_tags_client
- upm_textile
- zem_contact_lang (essential)
- zem_contact_reborn (essential)
There’s probably more I should mention, but I can’t think of it right now. Thanks for your gracious support!
Offline
Re: Design Opus: Making media to kindle and communicate Vision
Uhm, I’m not sure if your site displays the way it should in IE 6. For example: it doesn’t look as if the style of your headings is displayed correctly. And the search box is particially covering the right side of your logo.
I don’t have another browser available here at work, so I don’t if it’s an IE-specific problem.
…Prrrrrrrr…
Offline
Re: Design Opus: Making media to kindle and communicate Vision
I forgot to mention— IE6 has its own stylesheet, which delivers a stripped-down design that is still usable. I am experimenting with DD_belatedPNG on my development version with great results, but I haven’t yet made those changes to the live server.
Offline
Re: Design Opus: Making media to kindle and communicate Vision
Hey John! Site looks very promising. Now that you’ve laid the foundation, I’ll be interested to see what sort of content you’ll be putting up. Everything looks ship-shape in Firefox on Windows for me! *Subscribed
Thanks for pointing out Nathan Smith’s Feedburner article. I’ll definitely be implementing this on my own creations.
As for the 404 page – how did you manage to do that request_uri? That’s pretty darn helpful.
Txp admin themes | dropshado.ws – a blog for design noobs like me
Offline
Re: Design Opus: Making media to kindle and communicate Vision
nemoorange wrote:
Hey John! Site looks very promising. Now that you’ve laid the foundation, I’ll be interested to see what sort of content you’ll be putting up. Everything looks ship-shape in Firefox on Windows for me! *Subscribed
Thanks!
As for the 404 page – how did you manage to do that request_uri? That’s pretty darn helpful.
Here’s the relevant line of code:
<input type="text" id="search-ui" name="q" value="<txp:rah_replace from="/,-,%20,+,?=,_,&" to=", , , , , , "><txp:page_url type="request_uri" /></txp:rah_replace>" />
This goes in my search-ui form along with the other stuff necessary to render a search form. Then I have an output_form
call in my 404 page. When the page loads <txp:page_url type="request_uri" />
loads in the search input, and the rah_replace
plugin gets rid of the delimiters.
I don’t know if it really is useful, but I reckon I’ll know if I start seeing hits referred by the 404 page.
Offline
#6 2009-01-22 17:47:07
- els
- Moderator
- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: Design Opus: Making media to kindle and communicate Vision
I like the design very much, and the 404 page is great!
I think that in the to
attribute of the plugin tag you need to add a space before the first comma. At the moment it doesn’t replace the /
; So, when I’m on your page /is/
and I add sometext
to the URL (/is/sometext
) the text in the search field is issometext
.
Offline
Re: Design Opus: Making media to kindle and communicate Vision
Els wrote:
I like the design very much, and the 404 page is great!
Thank you, sir!
I think that in the
to
attribute of the plugin tag you need to add a space before the first comma. At the moment it doesn’t replace the/
; So, when I’m on your page/is/
and I addsometext
to the URL (/is/sometext
) the text in the search field isissometext
.
I tried it both ways, and I might go back to that.
The reason /
is replaced with nothing is that request_uri
always begins with a /
— and for some reason Textpattern’s search doesn’t find articles from multiword search queries when there is a space at the beginning. For instance, searching for semantic XHTML
works, but searching for
semantic XHTML
(with a leading space) doesn’t.
If there was a way to tell rah_replace
to get rid of the first /
and turn all the others into spaces, that would be ideal. Why does request_uri
have a leading /
anyway? If it weren’t for the leading slash, you could use <txp:site_url /><txp:page_url type="request_uri" />
to display the url of the current page, but that doesn’t work— you end up with a link that looks like this: example.com//section/title-of-article.
Last edited by johnstephens (2009-01-22 18:06:03)
Offline
Re: Design Opus: Making media to kindle and communicate Vision
Els wrote:
I think that in the
to
attribute of the plugin tag you need to add a space before the first comma. At the moment it doesn’t replace the/
; So, when I’m on your page/is/
and I addsometext
to the URL (/is/sometext
) the text in the search field isissometext
.
Fixed.
The solution was to edit the plugin, changing str_replace()
to preg_replace()
. This allowed me to use a regular expression to distinguish a leading slash in the request_uri
(which I needed to get rid of) from subsequent slashes (which I needed to replace with spaces).
str_replace()
and preg_replace
are not interchangeable functions— the PHP manual says:
If you don’t need fancy replacing rules (like regular expressions), you should always use [str_replace()] instead of ereg_replace() or preg_replace().
For that reason, I made a branch of Jukka’s magnificent plugin. It’s packed up and I think it’s ready to share. Let me know if you have any other suggestions!
Last edited by johnstephens (2009-01-23 08:14:46)
Offline