Forum Replies Created

Viewing 15 replies - 1 through 15 (of 19 total)
  • Thread Starter j.org

    (@jorg-1)

    Hi katzwebdesign,

    this is it! You’re the man.

    For the interested reader: I guess this line of code completely disables ACE’s page exclusion feature, but hey: this is what I wanted ??

    ~~~ Cheers.

    Hi acquaneve,

    unfortunately not, there isn’t a way to use this plugin widget-less. All options are set on per-widget-basis so allowing for a non-widget variant would also mean to embed an additional options page, doesn’t it?

    But I think the current way is already very flexible, so if you would tell me what you’re looking for, I possibly could point you in the right direction.

    ~~~ Cheers

    Hi AFox,

    yes – changing the format of date (and time) isn’t very convenient at this time, because it’s part of the translation files. The main reason for this decision was that date is automatically formatted according to your chosen language.

    However I am aware of this problem and up to now I didn’t have a good idea on how to allow for date format changes. Any suggestion is a good suggestion here.

    Attention: the line numbers are valid only for version 0.7

    But for a quick fix it should suffice to make the following changes. You can read about possible date format strings here.

    • For tag %STARTDATE%: Change line 963, replace
      __( '%d.%m.%y', LFM_US_DOMAIN) (which is a format which gets localized) with a string of your choice. E.g. '%A, %B %e %Y'
    • For tag %ENDDATE%: Change the same on line 964.
    • Tag %STARTTIME%: You’ll find it on line 965, again replace the whole
      __( '%H:%M', LFM_US_DOMAIN) with your own format, e.g. '%l:%M %P'.
    • For tag %DATE%: Here it begins to get complicated because this specific tag respects single and multi-day events, with and without a start time. The corresponding format strings (same pattern as above) can be found on line 943, 944, 947 and 950.

    So… as you can see this isn’t very difficult to change in principle, but providing a generic way to choose a arbitrary format isn’t that trivial.

    Another and way more enduring option would be to create a distinct translation file for English and use a satisfying format there. In that way you could support other users having the same problem.

    Best regards,
    j.org.

    Hi AFox,

    yes – changing the format of date (and time) isn’t very convenient at this time, because it’s part of the translation files. The main reason for this decision was that date is automatically formatted according to your chosen language.

    However I am aware of this problem and up to now I didn’t have a good idea on how to allow for date format changes. Any suggestion is a good suggestion here.

    Attention: the line numbers are valid only for version 0.7

    But for a quick fix it should suffice to make the following changes. You can read about possible date format strings here.

    • For tag %STARTDATE%: Change line 963, replace
      __( '%d.%m.%y', LFM_US_DOMAIN) (which is a format which gets localized) with a string of your choice.
      E.g. '%A, %B %e %Y'
    • For tag %ENDDATE%: Change the same on line 964.
    • Tag %STARTTIME%: You’ll find it on line 965, again replace the whole
      __( '%H:%M', LFM_US_DOMAIN) with your own format, e.g. '%l:%M %P'.
    • For tag %DATE%: Here it begins to get complicated because this specific tag respects single and multi-day events, with and without a start time. The corresponding format strings (same pattern as above) can be found on line 943, 944, 947 and 950.

    So… as you can see this isn’t very difficult to change in principle, but providing a generic way to choose a arbitrary format isn’t that trivial.

    Another and way more enduring option would be to create a distinct translation file for English and use a satisfying format there. In that way you could support other users having the same problem.

    Best regards,
    j.org.

    Hi AFox,

    seems like you’re deeply evaluating the plugin ;). I wished there were more people like you reporting bugs and providing solutions!

    Regarding the mentioned problem – I’ve tested the feature with my own API-Key and it worked without problems… Actually the plugin should delete this part of the format-string itself, but I’m glad you pointed this out: I’ll investigate it.

    Best regards,
    j.org

    p.s. Answering your other question in a minute ??

    Hey codeblue2k,

    I guess you just want to display a square detail of the picture, clipping everything else, like this? If that’s case the solution is CSS. Only for other reasons I modified the plugin code a bit, but the gallery view is handled by css. You either just edit the style file provided with the plugin (which gets overridden on updates) or modify your themes style.css. I think you need something like this:

    table#kpg-pictures td .kpg-thumb img {
    	left:-15px;
    	position:relative;
    	top:-15px;
    }
    table#kpg-pictures td .kpg-thumb {
    	border:1px solid black !important;
    	height:80px;
    	overflow:hidden;
    	position:relative;
    	width:80px;
    }

    The second rule makes the surrounding div square (80×80) and says everything which overlaps should be clipped, the first rule shifts the picture a bit to the top and to the left to make the shown part more interesting.

    Hope this helped a bit, maybe Guillaume can include some similar in his standard style file.

    ~~~Cheers

    Hi Folks,

    props to marcel – even if this doesn’t fix the cause of the error, it fixes its symptoms. Well done, I recommend this hack to everybody having problems here.

    btw – you can expect a new version of the last.fm for artists in the near future.

    regards

    j.org

    (@jorg-1)

    Mmh, I guess I’m responsible to avoid destroyed wordpresses ??

    In v2.7.1 the code line changed! Don’t use line 2168 anymore. To reintroduce this hack change line 2173.

    Be careful!

    j.org

    (@jorg-1)

    Unfortunately I’ve got little time to make bugfixes – situation will become better in march, I guess.

    But to clear things a bit up, I’m afrain it’s more complicated than you described: when I encountered this bug, I examined the cached events, and when there should be 2 events, there were 4 events, but the 1st was equal to the 3rd and the 2nd was equal to the 4th. So it’s not about caching a wrong number of events, it actually caches the duplicates – which is my reason to assume it may be an error of last.fm.

    But I have to review my own code before blaming last.fm, of course :).

    ~~~Cheers!

    j.org

    (@jorg-1)

    Sorry I didn’t reply earlier, many thing to care about currently…

    Your problem is weird: snoopy is a wordpress component, which is used to retrieve remote files. WordPress itself uses it to retrieve the feeds displayed on the dashboard, so it really SHOULD be there…

    I took another look in the plugin file and actually the error should occur on line 48…

    Are you sure you installed the most recent version? Did the plugin work before my suggested modification?

    The plugin requires a wordpress file called rss.php to get access to the mentioned component. This requirement is stated on line 43, so everything should be fine. You might want to check if there is something messed up with your copy of the file.

    I suggest the following:

    1. re-install the original plugin and try if it works out of the box
    2. if not, you maybe should contact the author, but I used this plugin myself, I swear! And as far as I know, there are no php5 dependencies.
    3. if it works, try to do change the mentioned url, and really nothing else, on one single line of the file.
    4. still no luck? reply here again (and prepare an email with the changed plugin file)

    I’m sorry you’ve got no luck with this, but I doubt we won’t get to work!

    ~~~Cheers!

    j.org

    (@jorg-1)

    Hi everybody,

    I looked into this last night and I’ve got bad news. It’s not just about some shorthand coding style, there are also some php5 features which are used in the core of my plugin, namely the new built-in dom-xml functions, which are quite easy to use for someone who has developed with the Domcument Object Model before.

    For supporting php before version 5 I would have to do massive modifications which would certainly result in a much heavier plugin. So my honest apologies for you all, but I can’t support anything before php 5.

    But if you are interested only the event lists, give Simon Wheatleys Last.FM Events a try. I used his plugin as a starting point ’cause I wanted more customization possibilities. Unfortunately you have to edit the code to retrieve artist events and not user events but it’s as simple as searching in lfm_events.php for ws.audioscrobbler.com/1.0/user/$username/events.ics and replacing with ws.audioscrobbler.com/1.0/artist/$username/events.ics.

    Hope this helps a little,
    ~~~Cheers!

    Hi selbic,

    yeah – you found the right thread, the php version is the reason for the failure.

    Mmhh… is there really such a great demand for using the plugin with php4? Then I maybe have to dig into this and release the next version compatible with php 4. But I guess this won’t be that easy.

    Anybody also interested in using this plugin with php4, pleasy reply here!

    Cheers!

    Indeed I encountered this strange behavior myself already, unfortunately I cannot explain why this happens. Nevertheless you found the workaround by yourself: clearing the plugin event-cache by dis- and re-enabling the plugin.

    Maybe the error is on the side of last.fm, but I cannot say anything sure about this.

    ~~~Cheers

    One further note:

    This way of reintroducing the feature IS NOT RECOMMENDED AND HIGHLY UNSTABLE. i.e. the parent-relationships get corrupted now and then, so be careful and don’t expect to much.

    Aside of that, it seems to work.

    Hi johnnyabracad,

    I just run into a similar problem and there definitely is some built-in stuff to magically convert linebreaks to paragraphs. However, it’s in general not advisable to use such a function directly (don’t know it btw) instead try to get post instances as they are delivered via the wordpress function get_posts($args) and afterwards use setup_postdata($post) to prepare the use of the_content(). The latter directly prints the desired content, including those missing paragraphs.

    I can imagine that this won’t get too easy from outside of wordpress, but this is the way I deal with it within my themes.

    Of course you can just try to mimic the same functionality by replacing linebreaks with paragraphs, but I doubt it will be easier.

    Hope this help a little,

    ~~~Cheers.

Viewing 15 replies - 1 through 15 (of 19 total)