It's Friday - what a day to visit jfoobar!

Jfoobar Labs

At jfoobar labs you will find "stuff" that is either cool, useful or for learning purposes. We hope to create a pretty nice selection over time. Remember, we need it to be fun.

Snippet - layout switching

  • Type: Code Snippet
  • Compatible: Joomla! 1.5+
  • Last update: 2009-06-19

Here's some code you can use in your template index file to switch between different layouts based on the menu tree -> menu item ID. You can do all kinds of funky stuff with this.

Comments 1

   

Snippet - Load module in article

You can load a module position in a Joomla! 1.5 article with following tag:


{ loadposition user7 }

Change user7 to a different position name to load the published modules for that position.

Comments 1

   

Snippet - Strict valid You Tube movies in your articles

If you want to put movies in your articles on a site with a strict doctype you will run into problems with the embed tag that is used by the default code YouTube gives you for example. Embed is actually not XHTML strict valid and this is because embed has been deprecated from XHTML 1.0.


<object width="425" height="344">
<param name="movie" value="http://www.youtube.com/v/M15hurmvnhI&hl=en&fs=1"></param>
<param name="wmode" value="transparent"></param>
<embed src="http://www.youtube.com/v/M15hurmvnhI&hl=en&fs=1" type="application/x-shockwave-flash" wmode="transparent" width="425" height="350">
</embed>
</object>

You can solve that by making a little change to the code:


<object width="425" height="344" data="http://www.youtube.com/v/M15hurmvnhI&hl=en&fs=1">
<param name="allowFullScreen" value="true" />
<param name="allowscriptaccess" value="always" />
<param name="movie" value="http://www.youtube.com/v/M15hurmvnhI&hl=en&fs=1" />
</object>

Comments 1

   

Snippet - Turn Joomla! pagetitles off in one go query

  • Type: Code Snippet
  • Compatible: Joomla 1.5+
  • Last update: 2008-11-24

In Joomla! there are article titles, component titles and also page titles. Lots of people don't want to use the page titles but they are set to show by default.

Comments 0

   

Snippet - Exclude folder from htaccess rewrites

  • Type: Code Snippet
  • Compatible: Diverse
  • Last update: 2008-11-22

When you are running a CMS, or for example a Blog you might also have SEO url's enabled through .htaccess rewrites. A common problem with these rewrites can be that you are no longer able to install a second application in a subfolder since those foldernames are included in the rewrites and can cause 404 errors.

Comments 7

   

Snippet - A little Joomla! editor extended plugin tip

  • Type: Code Snippet
  • Compatible: Joomla! 1.5+
  • Last update: 2008-11-19

If you have trouble with your editor extended plugin buttons where the right side of the button isn't handled correctly by the Joomla! admin CSS.

Look at the snippets, "blank" is a class in the admin CSS file that will fix what's missing.

Comments 1

   
moovur promo

JFoobar friends on Twitter

Follow JFoobar on twitter

Sponsored Links

Latest Comments

Aaron wrote:
2009-12-23 13:19:22 - Genius! Thanks, Wilco. I've been dying to take .
Posted in How to downlo .
Amy Stephen wrote:
2009-12-22 18:39:37 - Happy Birthday to one of Joomla!'s most noble - .
Posted in Mister Joomla .
Antonie de Wilde wrote:
2009-12-22 09:30:26 - Congrats Robin. Have a good day and watch out w .
Posted in Mister Joomla .
Robert wrote:
2009-12-22 08:51:02 - Happy Birthday Robin .
Posted in Mister Joomla .
Arno wrote:
2009-12-22 08:43:28 - Happy Birthday Robin, love your suit, you wife .
Posted in Mister Joomla .
Brian Teeman wrote:
2009-12-22 00:17:41 - Happy Birthday Robin, Welcome to the big four oh .
Posted in Mister Joomla .