Jump to content

Infusion creation example doesn't actually work


SergeantFTC

Recommended Posts

Following the example on the wiki results in an almost completely broken infusion. After typing it all in myself, I tried literally copying and pasting the contents of all three of the files from the wiki, with exactly the same results. Clicking on the refresh button does nothing, as in no notification, and no refresh of the DNSSpoof status. The DNSSpoof checking itself however does work correctly.

Entering and submitting some text in the large view results in a redirect to a broken webpage. I've attached a screenshot.
I assume this is because the wiki's content is out-of-date, and that it worked at one time. What changed, and how do we make it work?
P.S. Does this topic belong in the main Pineapple forum instead of the infusion forum?

post-48034-0-57331100-1418525274_thumb.p

Edited by SergeantFTC
Link to comment
Share on other sites

The reason why stuff is breaking is because whoever created this example put <head> tags in the HTML which should not be in there..

Replace your small tile code with this:

<script type="text/javascript">
function refreshSmall();{
refreshSmallTile(ExampleInfusion);
notify('You used the Refresh button!');
}
</script>
 
 
<?php
 
exec("pgrep dnsspoof", $dnsspoofrunning);
if(empty($dnsspoofrunning)) {
	echo "DNSSpoof is not Running.";
}
	else { echo('DNSSpoof is Running'); }
 
?>
 
<a href="#" onClick="refreshSmall();">[Refresh]</a>

That should work just fine.

Also for API documentation: http://wiki.wifipineapple.com/index.php/Webinterface_API

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...