titan21
Forum Replies Created
-
Forum: Plugins
In reply to: [Front End PM] Code ChangesHi Shamim,
Can you advise whether these changes will be incorporated into the new release?
Thanks,
Tim
Forum: Plugins
In reply to: [Front End PM] Code ChangesGood stuff! The code I’ve chnaged is the dispHeader function at line 1622:
function dispMenu() { global $user_login; $numNew = $this->getNewMsgs_btn(); $allNew = $this->getNewMsgs_admin(); $numAnn = $this->getAnnouncementsNum_btn(); $myconNew = $this->mycontact_new(); $conNew = $this->getcontact_new(); $spamNew = $this->getSpam_new(); $tocheck = get_option('fep_cf_to_field'); $label_newmessage = apply_filters("fep_newmessage_label", "New Message"); $label_messagebox = apply_filters("fep_messagebox_label", "Message Box"); $label_contactmessages = apply_filters("fep_contactmessages_label", "Contact Messages"); $label_announcements = apply_filters("fep_announcements_label", "Announcements"); $label_directory = apply_filters("fep_directory_label", "Directory"); $label_settings = apply_filters("fep_settings_label", "Settings"); $label_viewallmgs = apply_filters("fep_viewallmessages_label", "All Messages"); $label_contactmgs = apply_filters("fep_viewallcontactmessages_label", "All Contact Messages"); $label_spam = apply_filters("fep_spam_label", "Spam"); $label_newemail = apply_filters("fep_newemail_label", "Send Email"); $menu = apply_filters("fep_menu_open", "<div id='fep-menu'>"); $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "newmessage", $this->actionURL."newmessage", __($label_newmessage, "fep")), "newmessage", $this->actionURL."newmessage", __($label_newmessage, "fep")); $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "messagebox", $this->pageURL, sprintf(__($label_messagebox."%s", "fep"), $numNew)), "messagebox", $this->actionURL."messagebox", sprintf(__($label_messagebox."%s", "fep"), $numNew)); if ($tocheck){ if (in_array($user_login,$tocheck)){ $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "mycontactmgs", $this->actionURL."mycontactmgs", sprintf(__($label_contactmessages."%s", "fep"), $myConNew)), "mycontactmgs", $this->actionURL."mycontactmgs", sprintf(__($label_contactmessages."%s", "fep"), $myConNew));}} $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "viewannouncements", $this->actionURL."viewannouncements", sprintf(__($label_announcements."%s", "fep"), $numAnn)), "viewannouncements", $this->actionURL."viewannouncements", sprintf(__($label_announcements."%s", "fep"), $numAnn)); if($this->adminOps['hide_directory'] != '1' || current_user_can('manage_options')) $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "directory", $this->actionURL."directory", __($label_directory, "fep")), "directory", $this->actionURL."directory", __($label_directory, "fep")); $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "settings", $this->actionURL."settings", __($label_settings, "fep")), "settings", $this->actionURL."settings", __($label_settings, "fep")); if(current_user_can('manage_options')){ $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "viewallmgs", $this->actionURL."viewallmgs", sprintf(__($label_viewallmgs."%s", "fep"), $allNew)), "viewallmgs", $this->actionURL."viewallmgs", sprintf(__($label_viewallmgs."%s", "fep"), $allNew)); $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "contactmgs", $this->actionURL."contactmgs", sprintf(__($label_contactmgs."%s", "fep"), $conNew)), "vcontactmgs", $this->actionURL."contactmgs", sprintf(__($label_contactmgs."%s", "fep"), $conNew)); $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "spam", $this->actionURL."spam", sprintf(__($label_spam."%s", "fep"), $spamNew)), "spam", $this->actionURL."spam", sprintf(__($label_spam."%s", "fep"), $spamNew)); $menu .= apply_filters("fep_menu_button", sprintf("<a class='fep-button %s' href='%s'>%s</a>", "newemail", $this->actionURL."newemail", __($label_newemail, "fep")), "newemail", $this->actionURL."newemail", __($label_newemail, "fep"));} $menu .= apply_filters("fep_menu_close", "</div>"); $menu .= "<div id='fep_menu_open'>"; return $menu; }
And this was the original comment with the Pull Request on GitHib:
I was looking to customize a few areas of the plugin so was looking for filters/actions to plug into. I have rewritten the function dispMenu to include some filters for changing the label text for each of the buttons:
fep_newmessage_label
fep_messagebox_label
fep_contactmessages_label
fep_announcements_label
fep_directory_label
fep_settings_label
fep_viewallmessages_label
fep_viewallcontactmessages_label
fep_spam_label
fep_newemail_labelIn addition, I have created two filters to amend the html generated for the beginning and end sections of the menu area:
fep_menu_open
fep_menu_openI have also added a filter to enable styling of the buttons themselves:
fep_menu_button
This also allows the insertion of a css class for further styling if needed.
Are you planning on putting your code on GitHub as I may make some further amendments which may be useful to the plugin generally and Pull Requests would seem a sensible way of doing this.
Forum: Plugins
In reply to: [Collapse-O-Matic] Open Tab Based on URLThank you! I must have missed that one! Apologies. This seems to do the trick but one thing I’ve noticed which affects the site I am working on and yours in fact is that the opened tab is behind the static header you have. Is there a way to apply an offset so that it displays below this?
Forum: Plugins
In reply to: [410 for WordPress] 404 Logging removal methodHi – just to chime in here as it follows on from what clane121 was asking. I have a few links which turned up in the 404 list but I have resolved these by adding them to a 301 list. Am I okay just to find the entries in the MySQL table wp_410_links and delete those entries that I do not want to assign a 410?
Forum: Plugins
In reply to: [Recent FB Posts] Page OwnershipCheers! Sent ??
Forum: Plugins
In reply to: [Recent FB Posts] Page OwnershipCheers Danny,
Setting WP_DEBUG just gave me more “notices” so nothing fatal etc. I’ve checked that the FB application is public. I also removed the App from my profile an re-authorized which didn;t do the trick unfortunately.
What I did notice is that the permission for the the App was initially “Only Me” which I thought was the problem. It seems this is the default. I changed this to “Public” but still no dice.
Let me know if you need any more info or you need me to test anything.
Cheers,
Tim
Forum: Plugins
In reply to: [Recent FB Posts] Page OwnershipThat’s just it. No error at all. I usually put this top in the themes:
ini_set('display_errors',1); error_reporting(E_ALL|E_STRICT);
which should pick up any errors but when renewing the access token, the page just heads back to the Recent Facebook Posts options page and the API states “Not Connected”. The only error is a “Strict Standards Notice” in wp-includes/pomo/mo.php which isn’t related to the plugin at all as far as I know.
Totally stumped..!
Forum: Plugins
In reply to: [Recent FB Posts] Page OwnershipThanks Danny,
That’s what I thought. So I logged in with my normal Facebook credentials and the plugins still states that the API is “Not Connected” Is there any way of obtaining any error messages that may be occurring so I can diagnose the problem?
Cheers
Forum: Plugins
In reply to: [Post Thumbnail Editor] Plugin does not always load – white screenI had this issue today and found this thread https://www.ads-software.com/support/topic/edit-image-image-does-not-show-up?replies=10
Basically – check your functions.php and see if there is any leading or trailing whitespace – if there is – delete it! Had me scratching my head for about an hour but now all fixed! ?? Not sure this will help everyone but it worked for me!
Forum: Plugins
In reply to: [Post Thumbnail Editor] Wierd IssueNot sure. Happy to help if I can. What do you need?
Forum: Plugins
In reply to: [Post Thumbnail Editor] Wierd IssueGot it! The error from the URL was a “Strict Standards” error. I turned off my error reporting and all works as expected! I think this got me last time! Thanks sewpafly!
Just had a look at the code for “the_post_thumbnail” and you can specify a fifth argument as an array of attributes to apply to the element.
MultiPostThumbnails::the_post_thumbnail("my-post-type", "my-post-type-image", $image->ID, "my-post-type-image-size",$attr);
where $attr can be something like
$attr = array( "class" => "css-class", "id" => "my-id");
Worked perfectly for me.
Can I second this?
I love this plugin but recently I wanted to tag some img elements with html5 data attributes and the way I wanted to do this was through retrieving the src of the image and then constructing my own html.
Does anyone know of a quick patch that we could apply?
Forum: Plugins
In reply to: [Post Thumbnail Editor] No Step 2!Actually – I just had a thought, I am creating a theme at the same time as using this plugin and I usually dump the following at the top of my functions.php for diagnosing issues:
ini_set('display_errors',1); error_reporting(E_ALL|E_STRICT);
I just commented them out and now the plugin seems to work. Hope this helps. If you need a hand with testing , let me know.
Forum: Plugins
In reply to: [Post Thumbnail Editor] No Step 2!Thanks for looking into this sewpafly. I actually have just installed this plugin again today on a different site and I seem to have come across the same problem.
Which directory were you referring to? The plugin directory?