- This topic is empty.
-
AuthorPosts
-
April 21, 2016 at 6:15 pm #240802Doom_87Participant
Hello everyone.
I hope I’m putting this in the correct section!I’m trying to build a site with wordpress and I’m a newbie.
I’m using a plugin for excerpts on my posts, it’s called “Easy Custom Auto Excerpt”. However, the plugin does not offer the option to have ellipsis attached in the last word of the excerpt and it seems a bit weird to cut of a sentence like that.I wanted to ask if I could somehow edit the plugin’s php to add ellipsis attached to the last word of the excerpt.
I pasted it’s code below:
http://pastebin.com/SBQqb1i6I think it’s the correct php because it had many in it.
I tried contacting the plugin’s authors but they only made things worse since I gave them my login details and kinda messed up some things.
Anyway, I hope you can help me out and sorry if it’s a silly question :)
April 22, 2016 at 1:14 am #240805Paulie_DMemberI gave them my login details and kinda messed up some things.
Seriously!? Never, EVER, do this….
Multiline ellipsis is quite hard to achieve in CSS.
Whether it’s something PHP can do is beyond me.
April 22, 2016 at 2:32 am #240808SenffParticipantI always use my own function to show an excerpt of something, based on the number of words.
The function (put this in your function.php or custom plugin file):
function custom_excerpt($limit,$moreText = '') { $excerpt = explode(' ', get_the_excerpt(), $limit); if (count($excerpt)>=$limit) { array_pop($excerpt); if ($moreText) { $excerpt = implode(" ",$excerpt).'... <a href="'.get_the_permalink().'" class="read-more">'.$moreText.'</a>'; } else { $excerpt = implode(" ",$excerpt).'...'; } } else { $excerpt = implode(" ",$excerpt); } $excerpt = preg_replace('`[[^]]*]`','',$excerpt); return $excerpt; }
Within the loop, call it using:
echo custom_excerpt(40);
Or something like:
echo custom_excerpt(35,'Read full article');
April 28, 2016 at 8:56 am #241048pkinchlaParticipantwhat about
.excerpt:after { content:'...'; }
April 29, 2016 at 8:35 am #241095nkriscParticipantI tried contacting the plugin’s authors but they only made things worse since I gave them my login details and kinda messed up some things.
Off topic but, “wow.” That’s insane, you should never give a random person admin access to your site. For all you know, they’ve installed malware or other malicious code on your site.
April 29, 2016 at 9:02 am #241097SenffParticipantI’m a plugin developer and sometimes, when a user needs help, they offer to give me login info to check out their site. Most of the time I make clear that I can’t/won’t do that, to avoid any possibility of “hey something broke on my site now, what did you do??“
April 30, 2016 at 7:02 am #241107Doom_87ParticipantIs there a way to see if they have put any malicious code?
April 30, 2016 at 12:20 pm #241113SenffParticipantOnly if you know what you’re looking for. To go scour all the code and hope you stumble upon something malicious, might take a long while.
Then again, “malicious” is a broad term. Maybe they did something that messed it up, but that doesn’t necessarily mean it’s malicious (with bad intent).
But you could ask them what they did exactly, and then try to undo it all.
April 30, 2016 at 2:32 pm #241114Doom_87ParticipantI asked them and they just said that it’s their plugin’s issue and will be fixed in the next update, nothing else.
I don’t know if I’m sure what they mean.
Apparently communication is not their strong point, it makes me skeptical… :/May 1, 2016 at 6:29 am #241122SenffParticipantWhen you say “they messed things up”, does that mean things are still messed up when you deactivate their plugin?
It’s not really clear to me what you mean by it, so it’s hard to tell if they busted your site code, or some settings, or just did something to their own plugin, or…..
Either way, if you can clear up what it is they did, then it should be easier to undo it.
May 1, 2016 at 7:09 am #241124Doom_87ParticipantI don’t know what they messed up but I’ve seen speed drops that’s since they logged in that’s why I assume they changed something.
Another things that worries me is my Google Analytics Summary pages that shows:
Top Searches
www.share-button.xyz - 29 Visits (not provided) - 12 Visits http://website-stealer-warning-alert.hdmoviecamera.net - 2 Visits http://website-stealer-warning-alert.hdmoviecams.com - 2 Visits
Maybe it has nothing to do with the plugin but I’d like to know what you think.
Note that my site is closed to public by an Under Construction plugin since it’s not ready yet but I disable it from time to time to test things in a new private window.
May 1, 2016 at 10:46 pm #241149I.m.learningParticipantMy host’s server allows me to check my own analytics. I also keep lots and lots of backups for all my files. If I ever mess up bad enough, I just delete my server files and upload the latest backup files. That way, there is no doubt my code is free of errors.
I actually thought I was hacked because I saw a ‘pear’ error with my PHP; but then saw they had PHP Pear on one of my Cpanel options. Additionally, I do not have access to my htaccess file, this was when I tried to use their IPblocker.
I don’t use plug-ins. I do, however, link to other people’s site for Bootstrap. I do believe maxcdn is reputable and that is where I link, and many others too, for certain compatibility issues.
-
AuthorPosts
- The forum ‘Back End’ is closed to new topics and replies.