Unable to post link after clicking Preview button
-
(Thanks in advance for adding these features!)
Summary
There are a number of issues that arise when trying to post links. The issues range in form and function from two Cancel links/buttons to failure to load previews (possibly related to failed 301 redirects, among other potential issues). Because the issues vary depending on the URL, I’ll only use https://missoulaweb.design/ as my test URL.
Preconditions
- WordPress 4.9.4
- Customizr theme 4.1.19
- BuddyPress 3.2.0 with nouveau theme
- BuddyPress Activity Plus 1.6.4
- BuddyPress Members only 1.9.3 (but same happens with this plugin deactivated so probably not related)
- Viewing the New Post form with the cursor in the post message field
Steps to Reproduce
- Enter text in the post message field
- Click the Link icon to display the URL field
- Paste the URL into the URL field
- Click the Preview button (expected result is that the preview is shown, and it is)
- Scroll down a little to click Add link button
Expected Result
- Preview is still shown
Actual Result
- Preview turns to “There has been an error processing your request”
- There are two Cancels (one a link, the other a button) – these are present from before, in fact
- Clicking “Add link” button clears the form and fails to post the link
Workaround
- At step 4, click next to the Preview button (on the grey background, for example) to trigger the onchange event (or similar). The preview should fail with the error above.
- Click the Preview button. The preview should load.
- Click the Add link button and the link should post correctly.
Notes
- Once the link does actually post, it does not appear to have the standard post styles applied to it. Here is an example of what I’m seeing: https://48h.pics/SxkrxS30 (only valid for 48 hours from time of this post). Refreshing the page shows the post properly.
Not being familiar with how you are getting the preview, I think you might need to add -L (if it were via cURL) to follow redirects. You might also consider adding -k (skip SSL validation) but show a warning that the site is insecure. Also, I would remove the onchange event and only set the preview when the user clicks the preview button as it seems to be causing more issues than it solves.
Thanks again for the hard work and the helpful plugin. I hope this bug report makes it easy for you to find and fix the issue.
Kind regards,
Ted Stresen-Reuter
- The topic ‘Unable to post link after clicking Preview button’ is closed to new replies.