rockhopper72

Experience

35,845

2 Best Reply Awards

  • Member Since 2 Years Ago
  • 588 Lessons Completed
  • 1 Favorite

18th January, 2018

rockhopper72 left a reply on Issue With Class Bindings Not Updating • 1 month ago

Alright, I found a solution, but it seems like a hack.

I just used:

this.$forceUpdate();

17th January, 2018

rockhopper72 left a reply on Issue With Class Bindings Not Updating • 1 month ago

Update

I think I found the root of my problem.

Currently I have the variable slide change using the afterChange event listener from slick. This does change slide, but it doesn't update the component.

If I directly update the variable in my goToSlide() method, everything works properly, but using the buttons is not the only way to change slides (swipe on mobile, left-right keys, etc.).

Is there a way to force Vue to recompute class bindings?

rockhopper72 started a new conversation Issue With Class Bindings Not Updating • 1 month ago

Hello everyone, I'm trying to create a slideshow using Vue and slick. My issue seems to be that Vue isn't properly updating when the value slide is changed.

With this example:

<ul class="categories">
    <li><button @click="goToSlide(0)" :class="{ 'active': (this.slide === 0) }">Slide 1</button></li>
    <li><button @click="goToSlide(1)" :class="{ 'active': (this.slide === 1) }">Slide 2</button></li>
    <li><button @click="goToSlide(2)" :class="{ 'active': (this.slide === 2) }">Slide 3</button></li>
    <li><button @click="goToSlide(3)" :class="{ 'active': (this.slide === 3) }">Slide 4</button></li>
    <li><button @click="goToSlide(4)" :class="{ 'active': (this.slide === 4) }">Slide 5</button></li>
</ul>

My problem is that when the slide variable is changed, the active class is not applied to the button, but it is properly applied to the first button when the page loads.

I know the value of slide is changing, I have it output to the console.

Here is the link to the Vue docs for class bindings, but they don't seem to help me.

6th August, 2017

rockhopper72 left a reply on A Nice RESTful Way To Bulk Update 'order' On A Pivot Table , Thoughts? • 6 months ago

Maybe you could store the order column as an array on the Quiz model instead of the Question model?

4th May, 2017

rockhopper72 left a reply on TokenMismatchexception • 9 months ago

Are you sure the form contains a CSRF field that you submit with the form?

rockhopper72 left a reply on Route Controller Not Calling From Javascript Load Function • 9 months ago

The jQuery load method sends a GET request, instead you should use jQuery.POST

Something like this:

$.post( "/ajaxsender", {'sender_id': sender}, function( data ) {
  $( "#output" ).html( data );
});

Note: I did not test this.

30th April, 2017

rockhopper72 left a reply on Why Vue Js Replace The HTML With Comment ?? • 9 months ago

Just guessing: maybe the browser doesn't know how to render the component. Try installing [https://chrome.google.com/webstore/detail/vuejs-devtools/nhdogjmejiglipccpnnnanhbledajbpd](Vue Devtools) to get more insight into Vue-related elements.

19th December, 2015

rockhopper72 left a reply on Payment System • 2 years ago

I don't think Stripe offers a way to differentiate between which provider it is coming from. I believe they only accept credit cards (and Bitcoin, which they "convert" to your local currency), anyway. You can have different checkout buttons, such as ones that say "Checkout with Paypal", or "Checkout with Google Wallet", etc., and with one that says, "or pay with a credit card", and have that one use Stripe. This way you can control where each provider goes.

17th December, 2015

rockhopper72 left a reply on Mark A Series As Watched • 2 years ago

+1

rockhopper72 left a reply on Payment System • 2 years ago

I would recommend Stripe, Jeffery has plenty of tutorials on how to set it up and accept payments.

rockhopper72 left a reply on Force Download A Pdf File From A Base64 String • 2 years ago

You can try a link with the "download" attribute: http://www.w3schools.com/tags/att_a_download.asp

rockhopper72 left a reply on Scrolling Over Player • 2 years ago

I noticed this too and told Jeff, he said he is working on it. :-)

rockhopper72 left a reply on Laravel Routing Now Working • 2 years ago

Maybe it has something to do with the .htaccess file, or something with different versions of Apache? What error do you get?

10th September, 2015

rockhopper72 left a reply on Laravel Old Input Messing With Bootstrap Textarea • 2 years ago

I believe it is because the way the code is indented the html thinks that it is part of the content, similar to if you put it in

 tags. You should be able to fix it by doing something like this:

<textarea name="description" id="description" class="form-control" rows="5">{{ old('description') }}</textarea>

(making it all one line)

Edit Your Profile
Update

Want to change your profile photo? We pull from gravatar.com.