Remove the Rupee symbol in Laravel

0 votes

I want to see the rupee symbol on my webpage for the column.

Invoice page: enter image description here

When I Download it through an Excel file the rupee symbol should be removed it should look like this

Downloaded file: enter image description here

How do I do that?

Jan 6, 2023 in Others by Kithuzzz
• 38,000 points
1,525 views

1 answer to this question.

0 votes

Although there are other approaches you may take, I'm assuming the "export to excel" function is part of a front-end package like DataTables.

If so, you must intercept the data prior to the export operation. From the DataTables, this.

Example:

var export_data = table.buttons.exportData({
    format: {
      body: removeRupee
    }
  }); 

function removeRupee(data, columnIndex){   
  return ((columnIndex === 2 || columnIndex ===4) ? data.slice(0, -1) : data)   

}

If the export is generated from the backend, then I suggest you don't keep the currency in the same column as the value.

answered Jan 6, 2023 by narikkadan
• 63,600 points

Related Questions In Others

0 votes
1 answer

How to add Indian Rupee Currency symbol in Google Spreadsheet

To apply a custom currency format to ...READ MORE

answered Nov 8, 2022 in Others by gaurav
• 23,260 points
2,251 views
0 votes
1 answer

Using unserialize in PHP throws the same error repeatedly

I googled 'Node no longer exists', and ...READ MORE

answered Nov 14, 2018 in Others by DataKing99
• 8,250 points
1,594 views
0 votes
2 answers

How to get the URL of the current tab in Google Chrome?

Its so simple.... If you want to ...READ MORE

answered Aug 12, 2020 in Others by Steve
• 200 points
3,575 views
0 votes
1 answer

What is Laravel framework? Why one should use Laravel?

Laravel is a PHP web-framework; it utilized ...READ MORE

answered Mar 17, 2020 in Laravel by Niroj
• 82,840 points
1,682 views
0 votes
1 answer

How to download and install Lavavel framework?

Hey @kartik, First you must have xampp install ...READ MORE

answered Mar 17, 2020 in Laravel by Niroj
• 82,840 points
1,442 views
0 votes
1 answer

Display Laravel in browser by using cmd promt?

Hello, First you need to have laravel install ...READ MORE

answered Mar 17, 2020 in Laravel by Niroj
• 82,840 points
1,220 views
0 votes
1 answer

How can we get started with Laravel through Xampp?

Hii, First you need to start Apache and ...READ MORE

answered Mar 17, 2020 in Laravel by Niroj
• 82,840 points
1,017 views
0 votes
1 answer

What does the " @ " symbol mean in Excel formula (outside a table)

Excel has recently introduced a huge feature ...READ MORE

answered Nov 26, 2022 in Others by narikkadan
• 63,600 points
1,400 views
0 votes
1 answer

What are the important meta tags I must put in my website? [closed]

Regular meta info <title>{{pageTitle}}</title> <meta charset="utf-8"><!-- html5 version ...READ MORE

answered Feb 11, 2022 in Others by narikkadan
• 63,600 points
448 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP