Cant sign up using the Ajax code from help file

Spent days experimenting and I’m getting nowhere.
Phplist location: https://responder.lytica.dk/

Here is the code I use to sign up:

Email
<input type=hidden name="htmlemail" value="1"> 
<input type="hidden" name="list[1]" value="signup" /> 
<input type="hidden" name="subscribe" value="subscribe"/> 
<button class='button' onclick="if (checkform()) {submitForm();} return false;" >Subscribe</button> 
<div id="result" style="color: red;"></div> 

Tried html sign up:

	<div style="">
	<input type="hidden" name="list[1]" value="signup" /> 
	<input type="hidden" name="listname[1]" value="booksignup" /> 
Sign Up:
	<input name="email" placeholder="Enter email address" style="" type="text">
	<input name="name" placeholder="Enter name" style="" type="text">
	<input style="hidden" name="subscribe" value="Subscribe" type="submit"/> 

That makes TWO signup forms pop up and its only the latter that actually signs people up…

Think the manual does a poor job describing how to create a signup form.

@RigPa There is a working sign-up form at News – Ealing Civic Society
That might help you to see how yours is different.

Thanks! I tried it with the necessary corrections but alas… no luck. No signup and no confirmation mail. So it’s probably not the code…

Does it matter that I didn’t install in a subdir called list???

I get the failure message every time though.

@RigPa Use the developer tools in your browser to see the actual response from phplist.
Also check the event log page in phplist for any error being reported.

Thanks.

There seems to be no connection at all. Error 500.

I suspect the url as all parameters mentioned in the documentation seems to be ok.

@RigPa Please give the URL of the page where you have added the subscribe form.

THe URL is:

url: ‘https://responder.lytica.dk/?p=asubscribe&id=3’,

@RigPa I meant the page where you have added the ajax form.

Does the subscribe page meet the requirements shown in “Add an AJAX subscribe box on your website” Creating a subscribe page | phpList manual and your page includes the correct html and javascript?

phplist returns a 500 code when the subscribe attempt was unsuccessful for almost any reason.

@RigPa I have just looked at the subscribe page and it does not meet the requirements that I referenced.

Its been working for a while, but recently I had to move to another host and it stopped working.
Signup: https://lytica.dk/mail.html
phplist location: www.lytica.dk/lists/

Tried to install at the exact same location as before but it said: The pageroot in your config does not match the current location"". Check your config file. Which I did and there was no pageroot. Got this error over and over on fresh installations according to the manual. Gave up.

Not installing in a subdir made phplist run but the signup fails.

There is something wrong but I can’t find it. Read the documentation 20 times and spent 6 hours trying different things. Signup fails. No errors and nothing in the log. Checked the settings 20 times and it seems to be ok.

Going to this page, the links go to a different subdomain e.g. https://responder.lytica.dk/?p=subscribe&id=2

I’m sorry - I think you lost me here. I can’t figure out what you mean. Can you elaborate?

This is the link I use in my new installation is: https://lytica.dk/lists/?p=asubscribe&id=3.
Subscribe page ID is 3 from Config/Subscribe Pages

I took the number from the phplists_list table.

The manual says: * For consistency, the ID in brackets in the list[11] input should be that of your Subscribers list, the one that the Subscriber page is configured for (see Config/Subscribe Pages)

But the ID is listed nowhere on the referred pages. Only the Subscribe Pages are. So I took the number from the database.

The subscribe page is set to:
Don’t offer choice, default to html
Don’t display email address confirmation field

@RigPa The subscribe page id is shown on the listing of subscribe pages

image

The list id doesn’t appear to be shown anywhere, but you can see it by hovering over one of the buttons on the Subscriber Lists page
image