New tutorials and articles
January 23rd, 2010
I have just added to my site a tutorial on converting a Spry Menu Bar into a server-side include. I have also been busy adding a bunch of brief articles to the Dreamweaver Cookbook on the Adobe site.
I answer a lot of questions in the Dreamweaver forums, and realized that a lot of the solutions I was coming up with for people weren’t easy to find after a couple of days. So, rather than letting them disappear into cyberoblivion, I decided to add any of general interest to the cookbook when I had a few spare moments. The Dreamweaver Cookbook is intended for code samples, and doesn’t have the capability of including screenshots, so I’ll continue posting longer tutorials on my own site. But I hope you’ll find my contributions to the cookbook useful.
Here are direct links to some of the articles I have added to the Dreamweaver Cookbook:
- Create nested lists from a recordset
- Set a time limit on a login session
- Registration system that requires the user to validate the email address (in two parts)
- Alternate colours for table rows (using PHP, Spry, or jQuery)
- Upload image to website
- Format date for insertion into MySQL
- Formatting dates stored in MySQL
The Dreamweaver Cookbook is open to anyone to either request recipes or contribute recipes of their own. It could turn into a very useful resource if people start using it regularly. Check it out!
Entry Filed under: AJAX/JavaScript, Dreamweaver, MySQL, PHP
6 Comments Add your own
1. Mollie Twidale | February 16th, 2010 at 2:55 pm
I used your tutorial for changing the default tab for a Spry tabbed panel. Yes, it works, but the tabbed panel no longer works like a tabbed panel – it’s a single long page, and the tabs are not functional anymore. I followed your instructions, from downloading Spry 1.6. Is this the behavior you intended?
2. David Powers | February 16th, 2010 at 3:20 pm
No, it’s not what I intended. If the tabs are no longer functional, it sounds as though you have made a mistake somewhere. Without seeing the page you have built, it’s impossible to say. Of course, it’s possible there’s a mistake in my tutorial, but you don’t say exactly which tutorial you were using. So you don’t give me much to go on to help you.
3. Rose | February 21st, 2010 at 12:05 am
Dear David,
I’ve been following your tutorial on linking to another page and setting the default Accordion panel. I’m not able to get this to work. First of all, the javascript code for the accordion panel
var Accordion1 = new Spry.Widget.Accordion(“Accordion1″, {defaultPanel: params.panel ? params.panel: 0, useFixedPanelHeights: false});
always leave all my panels in the open state. Furthermore, I’m not able to get the panels param to pass through? I’m not sure since all the panel are already open. Here is the link I’m using:
<a id="content1" href="?recordID=&?panel=1#Accordion1″>
I would appreciate some input thanks.
Rose
4. David Powers | February 21st, 2010 at 8:18 am
Rose, It’s impossible to judge without seeing the actual pages, but if all the panels are open, it sounds as though there’s something wrong with the code on the page that contains the accordion. You need to get that sorted first.
Secondly, your link doesn’t make sense. It has got two question marks and a variable with no value. The href attribute should look something like this:
"somepage.html?panel=1#Accordion1".5. rose | February 22nd, 2010 at 1:06 am
Dear David,
Here is the code for the second panel that I’m experimenting with.
Doctor Who
<a id="content1" href="?recordID=&?panel=1#Accordion1″>
And here is the javascript code for the panel animation
I hope the above information is more helpful.
What I am doing is passing a php query via an URL to the detail section on the same page. This does work. I’m just trying to get the accordion panel that the user us currently in to stay open. My understanding is any php request cause a page refresh and that is why the panel always defaults to panel=0.
Thanks a bunch
Rose
6. Rose | February 26th, 2010 at 2:40 am
Update,
I finally got it all to work!
Apparently I didn’t have the code right in the header for the JavaUtils. Once I got that fixed then my panels opened and closed just fine.
Next, I added the tab=n in front of the panel=n#Accordion1 in the URL.
Just to let you know, your tutorial is a bit confusing at that point. I thought you were talking about tabbed panels AND accordion panels. Once I put that in, everything works great.
Leave a Comment
Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>
Trackback this post | Subscribe to the comments via RSS Feed