Adam
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Preview Images being squishedI only see examples of “squishing” not of “centering”?
Anyway, the squishing is done because you give the imgages both a width and a height. When both width and height are given, the browser will squish or stretch the image to fit. If you only define a width, the height will automatically be calculated retaining aspect ratio. The same applies to when you only define a height, in that case the width will be calculated maintaining aspect ratio. So you will want to remove either height or width.Forum: Hacks
In reply to: Random orientation of an image?I am unfamiliar with NextGen so I have no idea if there is a built in function for orientation? If not, your best option seems to be either jQuery (somthing like this plugin: https://code.google.com/p/jquery-rotate/) using Canvas, or CSS3 (transform). But both solutions will obviously not work in older browsers.
A more cross-browser solution would be using the gd library functions in php (https://php.net/manual/en/function.imagerotate.php).Forum: Fixing WordPress
In reply to: How To Load a iFrame Inside A PageIt is possible, one solution is discussed here: https://stackoverflow.com/questions/819416/adjust-width-height-of-iframe-to-fit-with-content-in-it
Forum: Fixing WordPress
In reply to: Running the control panel of the wordpressThat is because it isn’t there. What that entry tells you is that the memory limit is set to 32MB in wp-settings (via the function wp_initial_constants) and that if you want to override that you can add e.g.
define('WP_MEMORY_LIMIT', '64M');
to your wp-config.php file.Forum: Fixing WordPress
In reply to: Running the control panel of the wordpressForum: Hacks
In reply to: how to echo custom category from page categoryI am sorry, then I don’t know. since 2.9 (I think) taxonomies are possible on pages as well as posts. However pages work differently from posts, so perhaps the problem is the context in which you try to use them?
Hopefully someone else with more experience in taxonomies can shed more light on this than me for you.Forum: Hacks
In reply to: how to echo custom category from page categoryOh, my fault, sorry, can you try:
is_tax('page_category') {...}
I just rememebred that is_tax can take one argument.Forum: Hacks
In reply to: how to echo custom category from page categoryAnd you are trying to view pages where the page category is “hello”?
Forum: Hacks
In reply to: how to echo custom category from page categoryis_tax takes two arguments.
I suspect in your case it should be:
if (is_tax('page_category', 'hello')) {...}
Forum: Fixing WordPress
In reply to: Need help with a code for a different logo for each categoryI believe that in_category expects a categroy-id to be an integer (if it is a string it will assume a categroy-slug) so loose the quotes around 955 and see if that works.
Having said that, wouldn’t it work better with just CSS? The body element has a class .category-955 So you could do something like:
.category-955 #omc-logo {
background: url(‘logo-green.png’);
}.category-10 #omc-logo {
background: url(‘logo-blue.png’);
}etc.
Forum: Fixing WordPress
In reply to: Site refreshing itself??You are using a lot of different JavaScript libraries. The behaviour of reloading the page (what I see is that after clicking an image I get redirected back to the homepage?) looks to me as if there is a JavaScript problem. (instead of just catching and changing the click-event it seems that the default event is still triggered). So I suspect there is either an error in your JavaScript or 2 libraries are conflicting.
Forum: Fixing WordPress
In reply to: Create single Blog Page – In need of directionYour best bet would probably be to install WordPress on a subdomain (e.g. blog.yourdomain.com). The most work will be to adapt your existing design to WordPress as a theme. The alternative is recreating the whole site in WordPress. Both options have pros and cons.
The biggest disadvantage of the subdomain solution is that you need to maintain 2 designs (long term problems) while the other option has the disadvantage that it is more work in the short term.
But perhaps others have a better solution I didn’t think of.Forum: Hacks
In reply to: how to echo custom category from page categoryis_category only works on the Build in taxonomy ‘Categories’, so when you create your own taxonomy, you need is_tax
Forum: Hacks
In reply to: id="nuan_ria_plugin" – appearing on any page/postI found this as the first link when searching Google for nuan_ria_plugin: Answer
Forum: Fixing WordPress
In reply to: Adding HTML and Javascript into PHP for Menu itemsChanging an image on a link is exactly what you can do with CSS. Doing it with JavaScript is like ironing your shirt using a bulldozer; a bit too much.
While it is possible to change the default code of the navigation from within your theme (no need to mess with includes) there is really no need, since WordPress adds, very conveniently, its own id’s and classes which you can use for adding and changing the background image.
For example:#menu-site .menu-item-20 a { background: url('image-normal.png'); } #menu-site .menu-item-20 a:hover { background: url('image-hover.png'); }
This would apply the background image image-normal.png to a navigation-link, and when you hover over that link the background image would change to image-hover.png.