Jump to content

Mick23

Clients
  • Posts

    70
  • Joined

 Content Type 

Downloads

Release Notes

IPS4 Guides

IPS4 Developer Documentation

Invision Community Blog

Development Blog

Deprecation Tracker

Providers Directory

Forums

Events

Store

Gallery

Everything posted by Mick23

  1. Yes I did, thanks. I just used the inspector and can see that the images are present, but not visible (as the visibility of the image element is toggled based on a condition in the javascript. So that's one mystery solved 🙂 The first line of my initialise function is: initialize: function () { this._phrase = ips.getSetting('phrase'); ... } On dev this works fine, on my live env it does not appear to run at all. I'll put some console.log calls in to see if I can see where it's dying (or if it's executing at all).
  2. My web host has a really annoying spam filter that gives me 403 errors when I try to do this, so for now it's a workaround 🙂
  3. Hi folks, My application that is working in my dev environment is behaving differently (ie: not at all) when "installed" in the live environment. I realise that I may be missing some configuration steps here so please bear with me. I downloaded a new build of my application from the developer centre I uploaded the .tar file to my live applications directory I extracted the file into a directory of its own From the admin cp, I installed the application as it was now visible in the list Installation did not show any errors Going to the game page I do not get any php or javascript errors, and using the inspector shows that the javascript did not appear to run. Part of the page where there is supposed to be an image and a label that shows one of the template parameters. I should be seeing: Instead I see: Cheers! Mick
  4. Thanks everyone who has helped me so far, I've been making good progress on my project. Some context: A phrase is extracted from the database and used in the javascript code - the phraseId is also sent via template parameters. When the player wins or loses, I want to then call a controller method to set the results of the game they have just played, those parameters are likely to be something like: { phrase_id: 1234, result: 1 // 0 = lose, 1= win } What is the best way to approach this? Initially I thought I could use ajax to call the function like so (passing in phraseId and result): this._ajaxObj = ips.getAjax()( 'index.php?app=game&module=gameplayh&controller=gameplayh&do=endGame ', { data: { phraseID: 1234, result: 1 } }) .done( function (response) { }); But I am not sure how to return a simple "ok/true/false/whatever" from my php function? I have this code but I am doubtful about it: public function endGame () { if (isset(\IPS\Request::i()->phraseId) && isset(\IPS\Request::i()->result)) { # do something with phraseId and result here, write to database etc. } } I do not have to return a redirect as the user will trigger a new game using a button click (so they can view their results in the meantime). Thanks for any advice 🙂
  5. For a little more context... I'm trying to write a game where a word is selected from the database at random (working) but I need to access that string value in the javascript code in order to manipulate it. Do I have to write a function in the php controller in order to fetch the phrase rather than passing them in as parameters to the template? If so, how do I call it from the javascript?
  6. Me again (sorry I'm new at this, so forgive me if my questions seem a bit stupid)! Can somebody point me in the direction of getting the template parameters in my controller js file? eg: <ips:template parameters="$id, $name, $age" /> How do I (can I) access these in my javascript controller code?
  7. Thanks - I tried this but am now getting this error: $select = \IPS\Db::i()->select('COUNT(*) as cnt', 'hangman_phrase', array('status=?', 0), array('member_id!=', $member->member_id)); $result = $select['cnt']; Cannot use object of type IPS\Db\Select as array I removed all the code after the count($select) line and the error still occurs. I get the feeling it's probably something so stupidly obviously I'll kick myself when I see it!
  8. oops sorry, that's a typo there. $select = \IPS\Db::i()->select( '*', 'my_table', array( 'status=?', 0));
  9. Hi folks, I was going through the following page: And cannot get the following to work: // Get the select object $select = \IPS\Db::i()->select( '*', 'my_table', array( 'status=?', )); // Now, get the number of results returned $results = count( $select ); The $results = count ( $select) line is the problem, if I comment it out the error goes away. Am I missing something obvious here? Cheers 🙂 I should add that there are records in the table that match the query string, so results should be coming back.
  10. All I did was update to the latest chrome version and it started working again.
  11. I can also confirm this issue been resolved on my site. Thanks all! 🙂
  12. Thanks I have done so, the behaviour is still happening on my site and users have also mentioned it.
  13. This is also happening for reports, messages and pretty much anything to pops up.
  14. This is also happening on my forum. Can you tell me which plugin was causing the issue because I can't seem to find a resolution for it? This also happens when I click on reactions next to posts.
  15. Thanks @Stuart Silvester, I will let you know how it goes 🙂
  16. After much digging around it turns out the the passwords on the phpBB forum have been set using the argon2 hashing algorithm (due to a change in php versions). When the conversion runs, these passwords are not imported correctly into the member_pass_hash and members_pass_salt fields in the core_members table which causes the logins to fail. I'm not sure there is a solution for this except for everyone to change their passwords when they log into to the upgraded site. Any assistance would be greatly appreciated. I'd hate to have wasted my money on it 🙂
  17. Hi folks, I upgraded my old phpBB (3.3.2) site to Invision and everything went brilliantly until the users attempted to log in. Even my own test accounts that had been converted gave me a wrong password error and locked me out after 3 attempts. Has anyone experienced this problem before and know how to fix it? My members will not be happy if they all have to reset their passwords after the switch, and I really don't want to have to manually delete everything and re-convert. Please help!
×
×
  • Create New...