University of Oregon

Redux: Add a button to your wyswyg html bar in WP -Code2

As a follow up to Add a button to your wyswyg html bar in WP. I wanted to create a code button that prompts me for the code language. And if there’s none then use the simple tag.

So back to blog/wp-includes/js/quicktags.js. This time I needed to do more than add a simple button.
After a few attempts to do this from scratch I realized that I needed a function similar to the add link function that the link button uses. (more…)

WP Dynamic StyleSheet Switcher – stage 2

I added a background image array and integrated it with the rand() function.
Images from the free image section of bigstockphoto.com and iStockPhoto.

I also changed the html background color back to brown but the body’s is now the blue with a min-height:100% on the body and Layer1 so the image stick to the bottom of the screen not the bottom of the post. Then the brown earth color continues below that.
(more…)

Add a button to your wyswyg html bar in WP

NOTE: this post has a follow up here: http://pages.uoregon.edu/vid/2009/09/02/redux-add-a-button-to-your-wyswyg-html-bar-in-wp-code2/

I wanted to accommodate a new plugin I installed for highlighting code: Ion Syntax Highlighter. I was surprised that it didn’t append my quicktags button bar in the wyswyg edtitor.
I couldn’t remember the syntax either and I wanted to be able to use my button! I expected the behavior of the code button to change after I installed but not so. I did a quick search in the source and found that I needed to look for quicktags. I found what I needed here “blog/wp-includes/js/quicktags.js”

I duplicated the existing “code” code and and replaced instances of “code” with “code2”.

For example a search in the source of quicktags.js revealed this: (more…)

Enable your shell account on uoregon.edu

I stumbled onto these articles and I found out that we have access to a shell account on campus.

You can log in to your duck id page and enable or disable the account.
When it’s enabled you can ssh to your account or sftp (port 22) into your folder.
Each user’s folder is their username/duckid name and the url is uoregon.edu/~yourname.
For more info go here: cc.uoregon.edu/cnews/fall2005/ssh_uoregon.htm
(more…)