thinkstorm
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: BUG: wp_generate_attachment_metadata is missing functionno, but it needs to be in one of the files ?? I figured out that the problem is memory allocated on my server for image operations. A setting i cannot change sufficiently, so I just upload smaller images as a workaround.
Forum: Fixing WordPress
In reply to: prevent urlencode for php loop code?no, never… I also never figured it out ?? sorry for the lag, didn’t add this to my favorites before…
Forum: Everything else WordPress
In reply to: 4/25 Weekend Design Challenge CommentsFlyout menus are usually also not very good for accessibility by screen readers or braille bars.
One suggestion for the future (before demolishing everything until 2.8 release date): make the interface greasemonkey-friendly, so people could use at least thick-client based scripting engines to adjust their layout…
Mobile access and accessibility are both key for me.
Forum: Everything else WordPress
In reply to: 4/25 Weekend Design Challenge Comments!!! the flyout menus will be terrible to use from mobile devices !!!
any luck yet?
Forum: Plugins
In reply to: Unrelated tweetbacks spamming commentsyup, here, too… I just installed the new version – glad that I looked at the dashboard ?? I used the “cleanup” function on the settings page, and at least all the spam was gone…
I’m curious what’s going to happen tonight ??
Forum: Fixing WordPress
In reply to: Custom 404 error pageNot quite: if you call https://www.playoutintelligence.com/asdasdasdasd, the 404 page will not redirect to https://www.playoutintelligence.com/404.php
Maybe it’s also possible to check in the root index.php file whether
is_404()
, and then call<?php header("notfound.php", true, 404); ?>
The reason why I suggest to look at the root index.php is that I’m not sure if you can call the header(..) function anywhere within a page. If I remember correctly, this has to happen before the
<html>
tag is written…I would, however, definitely recommend using 404.php if the name of the URL is not important to you…
Cheers, Thorsten
Forum: Fixing WordPress
In reply to: BUG: wp_generate_attachment_metadata is missing functionMea culpa: the function image_make_intermediate_size is of course defined in /wp-includes/media.php. The problem for my thumbnails seem to be the GD function imagecreatefromstring that is called within wp_load_image in /wp-admin/includes/image.php.
This is a bit strange: when I use the file upload function within “write post”, JPGs are uploaded and thumbnails are created according to the Settings->Misc page. I am under the impression that media_handle_upload in /wp-admin/includes/media.php does call
wp_update_attachment_metadata( $id, wp_generate_attachment_metadata( $id, $file ) );
which is the same call I am trying to do. However, my call fails, the upload call succeeds… back to the drawing board…Forum: Requests and Feedback
In reply to: Title tags for imagesI posted a dirty solution that updates title and alt attributes from the media library (WordPress 2.5)
https://www.ads-software.com/support/topic/162762
I am not sure if that works for WordPress 2.3.3, and it is really really dirty programming. Maybe someone can come up with a cleaner solution I don’t have more time to look into this.
Cheers,
ThorstenForum: Installing WordPress
In reply to: Image Title Plugin?I posted a related solution (that is really really dirty right now, but works for me) at
https://www.ads-software.com/support/topic/162762
It basically uses information from the media library to update your title and alt attributes, so you can change the stuff there.
I really really recommend you use this as a template for your own needs, I’m not sure how long this will last ??
Forum: Alpha/Beta/RC
In reply to: How to Fetch Image Title/Description/LongDesc?I posted a quick and dirty solution at https://www.playoutintelligence.com/wordpress/ :
<?php /* Plugin Name: Lightbox 2 Plugin URI: https://www.stimuli.ca/lightbox/ Description: Used to overlay images on the current page. Lightbox JS v2.2 by <a href="https://www.huddletogether.com/projects/lightbox2/" title="Lightbox JS v2.2 ">Lokesh Dhakar</a>. Version: 2.5.0 Author: Rupert Morris Author URI: https://www.stimuli.ca/ */ /* Where our theme reside: */ $lightbox_2_theme_path = (dirname(__FILE__)."/Themes"); update_option('lightbox_2_theme_path', $lightbox_2_theme_path); /* Set the default theme to Black */ add_option('lightbox_2_theme', 'Black'); /* options page */ $options_page = get_option('siteurl') . '/wp-admin/admin.php?page=lightbox-2/options.php'; /* Adds our admin options under "Options" */ function lightbox_2_options_page() { add_options_page('Lightbox Options', 'Lightbox 2', 10, 'lightbox-2/options.php'); } function lightbox_styles() { /* The next lines figures out where the javascripts and images and CSS are installed, relative to your wordpress server's root: */ $lightbox_2_theme_path = (dirname(__FILE__)."/Themes"); $lightbox_2_theme = urldecode(get_option('lightbox_2_theme')); $lightbox_style = (get_bloginfo('wpurl')."/wp-content/plugins/lightbox-2/Themes/".$lightbox_2_theme."/"); $lightbox_path = get_bloginfo('wpurl')."/wp-content/plugins/lightbox-2/lightbox2/"; /* The xhtml header code needed for lightbox to work: */ $lightboxscript = " <!-- begin lightbox scripts --> <script type=\"text/javascript\"> //<![CDATA[ document.write('<link rel=\"stylesheet\" href=\"".$lightbox_style."lightbox.css\" type=\"text/css\" media=\"screen\" />'); //]]> </script> <script type=\"text/javascript\" src=\"".$lightbox_path."prototype.js\"></script> <script type=\"text/javascript\" src=\"".$lightbox_path."scriptaculous.js\"></script> <script type=\"text/javascript\" src=\"".$lightbox_path."lightbox.js\"></script> <!-- end lightbox scripts -->\n"; /* Output $lightboxscript as text for our web pages: */ echo($lightboxscript); } /* we want to add the above xhtml to the header of our pages: */ add_action('wp_footer', 'lightbox_styles'); add_action('admin_menu', 'lightbox_2_options_page'); ?>
the plugin has no options page, it is so dirty my eyes hurt, nine search and replaces with regular expressions that can go wrong, and I bet it slows down access times, too, and is probably not cacheable.
Please fix ??
Forum: Alpha/Beta/RC
In reply to: How to Fetch Image Title/Description/LongDesc?I thought about it a bit more… since the image is inserted hardcoded in tinyMCE together with the A-tag, I guess I need two hooks,
- tinyMCE Insert Image Hook, which puts a custom WordPress Plugin tag within the title and/or alt attribute
- post load hook, which replaces any the custom WordPress Plugin tag for the title and/or alt attribute tag within A-tag / IMG-tag with a lookup of its value from the database
I never programmed anything for WordPress yet, can someone please point me into the right direction in which .php files I would need to change code or how to add custom hooks (so wordpress updates don’t become a pain)?
Cheers,
ThorstenForum: Alpha/Beta/RC
In reply to: I don’t like the way 2.5 is goingI am using WordPress in a very basic manner, maybe a blog entry every week. For me a lot of things got easier, but I can see that a lot of plugins (like Flexible Upload) are not working anymore.
Well Ajax is “cool”, but the way it is implemented with the picture upload and browsing not really efficient – the space is too small to browse through the gallery, and loading takes a long time (and my flexible upload plugin doesn’t work anymore in the AJAX overlay…).
I wonder when I will forget to set categories and tags because I forgot to scroll down…