irislines web design
irislines web design

Show title settings not working

On a site migrated from joomla 1.5 to 2.5.7 the settings for showing titles are not being applied.

This has been a common complaint in th joomla forums and there has been some confusion about the multiple places that this parameter can be set.

What I found is that the way this is stored in the database is different.  The 2.5  install uses JSON formatting for this field and when I open a menu item and save it, it gets put back in the database in the new format and then works as expected.

What is needed is for this formatting to be accomplished in the migration process.  In the meantime I’ll try a SQL find and replace.  

Widgetkit provides responsive slideshow solution

I had discovered widgetkit when I needed a great mp3 player that did not rely on flash.  Widgetkit ALSO provides a pretty friendly slideshow solution that does not combine cropping and resizing as the ckslideshow extension does.

CK Slideshow might be a good solution if your slide images won’t suffer from being cropped — the smaller images delivered on a mobile device will be a vertical slice of your horizontal banner image, rather than just a proportionately reduced banner.    In some cases this would be a better solution — but banner images would have to have good content in the middle of the banner image and often that is NOT the composition we’d prefer for the larger images.

Tradeoffs!  

Permissions for global_checkin can’t be set

I tried to have administrators use the global checkin function on a Joomla 2.5 site and in spite of how the permissions were set, the administrators did not have access to use the global checkin.

I found this solution on the joomla forum (http://forum.joomla.org/viewtopic.php?f=616&t=642208)

“The reason why we can’t give access to administrators is that Joomla team hardcoded permision for com_checkin (and some others) inside the component itself. So it is irrelevant what do we do on admin panel. This is quite stupid, because Joomla could simply hide options for permissions if that does not make any change.

Now, the solution:
Open file administrator/components/com_checkin/checkin.php and find  line 13

Code:
// Access check.
if (!JFactory::getUser()->authorise(‘core.admin’)) {
   return JError::raiseWarning(404, JText::_(‘JERROR_ALERTNOAUTHOR’));
}

This code causes the problem I was talking about. Change it with this to allow this component to be controlled by permissions settings.

Code:
if (!JFactory::getUser()->authorise(‘core.manage’, ‘com_checkin’)) {
   return JError::raiseWarning(404, JText::_(‘JERROR_ALERTNOAUTHOR’));
}

BT Content Slider

I’m upgrading a site from J1.5.26 to J2.5.6 and needed a replacement for an extension that will not work in 2.5:   the Ultimate Content Display extension.

Today I found a free extension from bowthemes.com  called BT Content Slider.

With persistence I got it to work but….  there are a few caveats:

I needed to be able to select article to display in a sidebar module — one at a time,  fade in effect as they rotate from one to another.

The format for entering items is this:    id1, id2, id3 (1,2,3)

where the numbers are the article item ids.

There’s another place to specify article order — and I was having trouble with this — some articles just wouldn’t show up, even though I knew the id was good.

What worked:   be sure list is in low to high order by ids   AND  set order to “random”.

OK.  I can live with that.

Another issue came up though with an article that had no associated menu item.  

The BT Content slider has a parameter for you to set a menu item “if the article id is not found” —  I figured this was a placeholder article to show if the content selection tool had no results.   But NO!    If an item is found, it will display the page header of the menu item set in this parameter.    Odd results — click to see a schedule of an event and get “Ways to Give”  as a heading over the schedule content.    NOT OK!

So… the MORAL of this story is to use that hidden menu — and be sure all articles exists in at least one menu — even if its only the hidden menu.

May I give a plug for NoNumber.nl‘s wonderful Add to Menu extension.   Create your menu item right from the article creation/edit screen!

 

Omeka and Word Press on same server…

I’m working on a project that started out as a word press blog with an installation of Omeka in a sub-directory.   Once enough work was done in Omeka  they wanted that at the root url.   OK.  Rather than uninstalling the WP site,  I moved it to a sub-directory,  moved Omeka up and all was well.   I tested access the the WP site in its new location before moving Omeka, and all was well.

But…   today they tell me they want a blog, too — so I figure I’ll just link to the install we already have and all will be well.

Not.   Omeka’s htaccess includes code to disable any .php other than their own index.php and although I could SEE the blog,  I couldn’t access the wp-admin.

Omeka’s Google group archive revealed the solution:

I added this:

 

# suggested in Omeka google group # Disable URL rewriting within this directory
RewriteEngine Off

# Undo Omeka’s .php blocking

    Order Deny,Allow
    Allow from all

to the .htaccess in the wordpress  subdirectory  and — problem solved!

Let’s hear it for support groups,  and google for helping us find the relevant posts!

 

Invalid entry

Ever get the message  “Invalid entry”  when trying to access the Joomla! backend?

The url will be   yoursite.com/administrator/index.php.

You know the password is correct,  but maybe a session cookie is getting in the way…

Try deleting the /index.php from the url — for me,  I find that it let’s me back in.

 

 

How to repair Joomla _session table.

A recently launched Joomla 2.5 site was down this morning with the following error:

Table ‘./xxxx_suffix/xxxx_session’ is marked as crashed and should be repaired SQL=INSERT INTO `xxxx_session` (`session_id`, `client_id`, `time`) VALUES (’87b1b689ed654ea16833779add58ee44′, 0, ‘1342450283’)


Repairing a database table is not difficult,  but the error causes panic for the clients and I am not always sitting at my computer….

I created a ScreenSteps tutorial on how to handle an error like this and share it.

How to repair SQL database table

Joomla Bamboo template fix

The center column of my site, using Joomla Bamboo’s Meridian template was not behaving.

The template uses javascript to calculate the height of the columns and some tabs and sliders were causing problems.

Anthony wrote:

“The code at the bottom of the js/template.js file. The crucial bit is: jQuery(‘ul.jbtabs li,.moduletable-panelmenu span.mainlevel,h3.pane-toggler’).click(function(){ setTimeout(calculateEQ,200); }); The 200 is the delay in ms for the script to calculate the height of the item. In your case because the accordion content was large we set it to 500. The selectors that trigger the function are here: ul.jbtabs li,.moduletable-panelmenu span.mainlevel,h3.pane-toggler So you just need to add your selector there to get it to work.”

Today I had to add another selector:  h3.pane-toggler-down  so that a weblinks list spilled open would be considered in the calculations.  I didn’t need to submit a new ticket or ask for help, I just needed to access the ticket explaining how the problem was solved the first time.

The pesky part was that I had to renew my account to be able to access the old tickets with this solution.  So from now on I’ll remember to document solutions here as well and not rely on the ticket system from a limited-time support contract.

Device detection to single out the ipad for special styling

”   on the body element of the index.php file.

(Of course I also added a line to the template with that variable for testing  that would display the results and not force me to examine the code to see if it was working.)

In my stylesheet I could then write rules specifically for the ipad:

.ipad  element-needing-custom-styles  {property: value;}

I was doing this to solve a problem with how the quicktime player displayed on the ipad (fallback for no flash when using Allvideos)

I increased the height of the player container to 72 px in the plugin parameters,  then set the theses styles:

/* adjust allVideos audio player */

.avPlayerWrapper {text-align:left; width:230px; clear:none; }
        .avPlayerWrapper .avPlayerContainer {margin:0;}

.avAudio .avPlayerContainer {height:24px; overflow:hidden; }
        .avAudio .avPlayerBlock {position:relative; top:-48px;}

#ipad .avAudio .avPlayerContainer {height:72px;}
         #ipad .avAudio .avPlayerBlock {position:relative; top:0;}

The results made mp3 players that were ugly, but functional.

The much better solution was to use WidgetKit’s Media Player from YooThemes.com, but I’m still glad to know how to target the ipad specifically should I ever need to.

-->

My friend and colleague Bill from Grumpy Engineering  helped me with this one:

I added this to the php block at the head of my template:

$isIPad = preg_match('/ipad/i', trim($_SERVER['HTTP_USER_AGENT']));
if ($isIPad) $device="ipad";
else $device="not-ipad";

and then could use

class=“<(question mark)php echo $device;  ?>”   on the body element of the index.php file.

(Of course I also added a line to the template with that variable for testing  that would display the results and not force me to examine the code to see if it was working.)

In my stylesheet I could then write rules specifically for the ipad:

.ipad  element-needing-custom-styles  {property: value;}

I was doing this to solve a problem with how the quicktime player displayed on the ipad (fallback for no flash when using Allvideos)

I increased the height of the player container to 72 px in the plugin parameters,  then set the theses styles:

/* adjust allVideos audio player */

.avPlayerWrapper {text-align:left; width:230px; clear:none; }
        .avPlayerWrapper .avPlayerContainer {margin:0;}

.avAudio .avPlayerContainer {height:24px; overflow:hidden; }
        .avAudio .avPlayerBlock {position:relative; top:-48px;}

#ipad .avAudio .avPlayerContainer {height:72px;}
         #ipad .avAudio .avPlayerBlock {position:relative; top:0;}

The results made mp3 players that were ugly, but functional.

The much better solution was to use WidgetKit’s Media Player from YooThemes.com, but I’m still glad to know how to target the ipad specifically should I ever need to.

Joomla solution for non-flash mp3 player

I searched the JED and the best I could come up with was to use Allvideos to create simple, single mp3 players for a website I’m working on.

The syntax of this pluggin is nice and simple:   {mp3}Name-of-file-without-extension{/mp3} or

{mp3remote}http://other-site.com/name-of-file-with-extension.mp3{/mp3remote}

But…  Allvideos uses Quicktime as a fallback when flash is not available and on the ipad the Quicktime controller was clunky.   I did get a snippet of php to detect the ipad and then could address styling the controller to make it better — but it was still clunky.

WidgetKit from youtheme.com

I kept looking for a solution that would provide html5 audio  and finally found it in youtheme’s widgetkit media player.   This uses html5 audio and falls back to flash instead of the other way around.  It suits me!

The syntax is just a bit more complex, but certainly doable:

 

IrisLines LLC
101 Washington Street
Brattleboro, VT 05301

802 257 7391

info@irislines.com