unexpected t_string in plugins/exec-php/includes/runtime.php

Ahh the old unexpected T_STRING error message.I’m familiar with causing this error, not fixing it.So I headed over to the Exec PHP plugin home page to sniff out some way of making it go away.
Keeping in mind that in one Page where I’d used the plugin to display a list of pages it worked just fine I read the terse explanation of why I might be getting this error:

If you experience a PHP error message like ‘Some error in /home/minime/htdocs/blog/wp-content
/plugins/exec-php/runtime.php(41) : eval()’d code on line 4′ then it’s time to repair your PHP code. If you are unsure where your code breaks, first run it in a separate file to punch out all bugs and afterwards copy the code into your article or widget. To reduce the noise in the comments section of the plugin homepage I will delete all entries refering to this topic.

Yikes.It’s totally my fault,then.So what did I do to cause the error? I used an apostrophe
in an array or string or whatever the kids like to call it.
I was using the wp list pages template tag I got from the WP Codex
[php]<ul>
<?php
wp_list_pages(‘include=5,9,23&title_li=<h2>’ . __(‘Poetry’) . ‘</h2>’ ); ?>
</ul>
[/php]
Except instead of (‘Poetry’) I’d written (‘Mens’) and the punctuation mark was what caused the error.

I re-worded the title and the error message went away and the code executed.
Oftentimes I’ve gotten errors for something as easy to fix as my last mistake.
The first assumption one might make is that it’s the plugin causing this error.But since it worked elsewhere I knew it couldn’t be the plugin’s fault.
So I deduced that it was code I’d altered (see above) — the other code I used I hadn’t altered.
I hope this helps someone else who gets the same error and hopefully it is as simple to mend.

More Crossbrowser Complaints

After the debacle of my last project rendering so unexpectedly,I was curious to see if my other websites looked fine in Linux OS, since I never have access to that kind of machine.
I visited browsershots.org again and loaded a couple of pages from the stonestreetpress.com website.Now I’m even more confused.Because both pages look pretty the same, even in IE 5.5 and I was sure there would be discrepancies.
The home page of ssp.com is kind of complicated and has floated divs and lists and whathaveyou all over it.Yet it renders just fine.
So why does that one simple html form not render 100% accurately in Linux?
Just to show you what I’m talking about here is a group of screenshots in a bunch of browsers
Except where the machine’s screen cuts off the bottom of the page in some of the screenshots-they all look the same.
I’m officially stumped.

Form Munching, Cross-Browser Style and tables layout

I recently completed a project where I had to create and design an html form and redesign an html page that was supposed to look like all the rest of the website–except my one page would be using a Doctype, a style sheet with no CSS errors and XHTML with no validity issues.

I had become pretty rusty with forms so this was a refresher class for me.

I have the ability to switch from Firefox 2.0.0.11 (pesky version decimals)– and IE7. I also have Opera 9.25. So I was able to check the page in 3 browsers but only one machine…and to be assured that everyone will see every single question in the html form I wanted to check with browsershots.org just to be on the safe side.
I also used Google Analytics tracking code to see what systems/browsers visitors were using and the majority of 164 visitors were using Windows IE 7 with IE 6 not far behind.Those visitors could see the entire form and the style looked correct.
Linux visitors were about 11 out of 164, using Konquerer,Galeon and *Firefox. They saw about 40% of the form. Horror. If they don’t see all the questions in the from fields how can they fill it out? *Ubuntu using FF 3.0 loaded a blank page. I can only hope that visitor knew how to turn off page styles.
The facts are:my page is 100% XHTML Transitional and has the correct Doctype and CSS with no errors.
So why can’t all the 30 browsers that browsershots.org has in it’s list of factories see what they’re supposed to see?
Is my stylesheet wrong? Is it the form tags I’m using?
All other the other pages from the site are built in tables with no doctype and no stylesheet.
I wanted to see how another page from the website with a long form
(tables layout,quirksmode,no stylesheet) would render cross-browser style.
Absolutely fine across the board.
So what’s the conclusion?
In order to have your html form render properly across a variety of browsers and operating systems do you have to skip the stylesheet,doctype and use a tables layout?
Has the WC3 led me down the garden path?
Because I was under the impression that this trifecta (doctype,valid html and error free stylesheet) would assure cross browser compatibility.

Note*

After I wrote this I spent more time on browsershots.org and borrowed my roommates macbook.
Browsershots.org isn’t infallible.Their screenshots depend on what they call a factory which is a combo of hardware,an os and a browser.So things can go wrong. Pages don’t load completely and queues get so long that screenshots expire. You used to have the option of picking when your queue’d screenshots expired but now you get a 30 minute window.If the queue is over 30 minutes long you might be stuck hovering over the extend button, which is a drag. But, ok this is a free service and one must not look a gifthorse in the mouth.

On second thought…

My worrisome page looks exactly as it’s supposed to on my roommate’s MacBook with Tiger OS and Firefox 2.0.0.1.1 (not sure where all the decimals go).But from the screenshot with that factory the form looked as though it was getting mulched.

Yet another conclusion:

The only way to be 100% certain of how your site/page looks in a variety of browsers/machines and OS’s is to physically have access to those machines.

Final conclusion:

You can satisfy most people most of the time with valid code,valid stylesheet and correct doctypes-but you can’t satisfy them all. And it is just not worth aggravating my already hyper OCD over this matter!

Youtube equals exposure and site visitors.Duh!

On the internet, when something is viral it’s a good thing, viral content spreads very fast and infests everyone with its greatness. Just kidding.
Youtube seems to be as popular as breathing.So we should use it to get exposure for our websites,right?
I recently opened an account there for a client of mine who has a member’s site and store for fetish clips he directs.The content is adult but relatively tame because there isn’t any full frontal nudity or xxx shenanigans in the clips.
His is a unique case study because his content is the proverbial Heroin Content,and people really, really want it.Heroin Content+Youtube=Viral-ity?
What I’m wondering is if your content isn’t as compelling as my client’s can an account on Youtube still help you get site visitors?
What if you take a 30 second digital camera video of your dog in the park,then load it to Youtube.
How many site visitors will you get?
I’ve seen many clips on Youtube that were so random but got so many views that I’ve come to the conclusion that people will watch anything as long as it is free.
My client’s Youtube account has only been active for 2 days and already is in the top 54 most viewed.He has 24 subscribers in 2 days and these people are definitely going to the website from Youtube.So what took me so long to think of Youtube?
Well, he wants to sell and Youtube is free.That was what made me think twice about it.But he had samples of the full length clips for the free tours and lots of them and I wanted to be able to show them in his site in a better looking format than with an embedded media player–which as you know looks dated and uncool.
So as a test I loaded a sample clip to Youtube and the outcome was actually surprisingly good.The clip quality isn’t as good as the raw .wmv file but it’s good enough.As I was testing it out his account got 5 subscribers in one hour. And more subscribers when I loaded more clips. My original plan was just to use Youtube’s technology to post sample clips on the tour pages. But his account popularity boomed overnight and I rethought my plan.
The tour pages were originally static with some image galleries and a few sample clips with embedded media players.I remade the tours with WordPress which gave me access to the spectacular plugin by Jens Cornell which has to be the easiest plugin for getting Youtube videos in a post. The usage of the trifecta of Youtube, WordPress and Heroin Content seems to be a great success as far as site traffic goes… But the goal is to get folks to the shop and buy clips so I will just have to wait and see the results.