Comments (5)
Hello @2jiwon, thank you for using the yoeunes/toastr
package. I noticed that you are currently using an outdated version of the package. To resolve any potential issues, I would recommend upgrading to the latest version by running the following command: composer require yoeunes/toastr::^2.3
.
Additionally, I suggest removing all the code related to the outdated version from your blade template. This should help ensure that the latest version works seamlessly with your project. Thank you again for using this package, and please let me know if you have any questions or concerns.
from toastr.
@yoeunes Thank you for your reply. I tried what you suggested composer require yoeunes/toastr::^2.3
then it says
[UnexpectedValueException]
Could not parse version constraint :^2.3: Invalid version string ":^2.3"
so I also tried composer require yoeunes/toastr^2.3
just in case, but it didn't work either.
from toastr.
@yoeunes oops, nevermind. it was because my composer version. I was able to update to 2.3.
However, the situation that showing up twice is still exists.
from toastr.
please remove all this code from your blade template:
@if (Session::has('success'))
<div class="row justify-content-end">
<div class="col-3 col-align-self-end alert alert-success alert-block">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>
toastr.success("{{ $message }}");
</strong>
</div>
</div>
@endif
....
<!-- container-fluid end -->
@toastr_css
@toastr_js
@toastr_render
from toastr.
when i add this
layout app.blade.php
@toastr_css
@toastr_js
@toastr_render
PHP 8.1.17 (cli) (built: Mar 14 2023 23:07:43) (ZTS Visual C++ 2019 x64)
Copyright (c) The PHP Group
Zend Engine v4.1.17, Copyright (c) Zend Technologies
laravel . 10.18.0 version
Here my PostController Code
$post = Post::create([
'title' => $request->input('title'),
'description' => $request->input('description'),
'slug' => Str::slug($request->input('title')), // Generate slug
]);
if ($request->hasFile('avatar')) {
$post->addMedia($request->file('avatar'))
->toMediaCollection('avatars'); // You can customize the collection name as needed
}
toastr()::success('Post created successfully!', 'Success'); // Display a success toast message
//
Undefined function 'App\Http\Controllers\toastr'
//
any one help me fix htis
from toastr.
Related Issues (20)
- Using toastr with ajax HOT 4
- The default CSS class 'toast' gets overlapped by Bootstrap HOT 2
- Error Class 'Yoeunes\Toastr\ToastrServiceProvider' not found HOT 1
- Hwo to work using jquery ajax
- Toast
- jQuery Clashes HOT 4
- Not popping up when used in methods HOT 3
- vscode undefined function toastr() HOT 2
- Jquery conflict being duplicated on the page with the toast HOT 4
- How to translate the messages HOT 3
- Hello there is problem in jsdeliver cdn in egypt https://cdn.jsdelivr.net/npm/@flasher/[email protected]/dist/flasher.min.js is blocked in egypt what is the replacement ? HOT 5
- display tostr but without background color
- The Toast only is showed on next refresh HOT 1
- toastr destory or clear not working? HOT 3
- The response is not a view. HOT 2
- Not working on AJAX CRUD
- Please help, how remove default icons from toast
- Error Installing/Update toastr in Laravel 11 HOT 1
- toastr.clear() HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from toastr.