Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Merge 2.2.5 into master #67

merged 17 commits into from Apr 2, 2012


None yet
3 participants

tm1000 commented Mar 23, 2012

Mainly moving connectwise.

All in favor say 'I'

Why not wrap the result with trim e.g. value = trim($row["name"]);
Then lower down strlen and trim would be consistent.


ukstevef commented on 2eb6159 Jan 10, 2012

Added to list for v3.x source migrations - see #42

Checks status of 'cache results' in Caller ID Lookup sources and warn…
…s if enabled. Permits 'cache results' to be changed from within the scheme config. This commit has a text box in scheme config but it needs to be changed to a checkbox.

ukstevef commented on page.superfecta.php in 43ea99e Jan 10, 2012

To set a check box you could use
<input type="checkbox" name="cache" value="Use Cache" checked>

If conf was a check box control, you could test document.forms.Superfecta.conf.checked

The problem is in this line (262), I have tried every which way, but the only thing I can get a checkbox to do is reflect the status of 'cache results', I can't get changes to the checkbox to save.


ukstevef replied Jan 10, 2012

The form is doing a post back to itself.
If you add the checkbox you should see cache=off in the post variables inside function Ht_Generate_List


lgaetz replied Jan 11, 2012

With javascript, I am way out of my comfort zone and I my efforts are not working. Can someone spruce up line 262 to make this work then it should be good for testing.


ukstevef replied Jan 11, 2012

OK, after a bit of debugging it looks like checkbox values are not posted if they are empty.
You can prove this by putting

print("<h2>Posted data - start</h2>");
print("<h2>Posted data - end</h2>");

This will dump all the post variables, try saving the form with the checkbox set, and you will see it.

I added the checkbox locally with
```<td><input type="checkbox" name="cache" onclick="toggleCache(this);" value="off"></td>

You can then check isset($_POST['cache']) and then issue your SQL.

the javascript function toggleCache has
function toggleCache(ctlCache) { if(ctlCache.checked) { ctlCache.value = 'on'; } else { ctlCache.value = 'off'; } }


ukstevef replied Jan 12, 2012

Having slept on this, the solution is easier.
Add the checkbox with a default value of on and if the cache is on set the checked attribute of the checkbox.
You do not need the javascript, when looking at the post data the value will only be there if it is on.


tm1000 commented on 43ea99e Jan 11, 2012

Nevermind I was wrong


lgaetz commented Mar 23, 2012

I did a bit of last minute testing and it looks good to me. I vote AYE!

tm1000 added a commit that referenced this pull request Apr 2, 2012

@tm1000 tm1000 merged commit a6d7676 into master Apr 2, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment