94251/how-do-i-remove-http-https-and-slash-from-user-input-in-php
Here is my example user input
http://edureka.com/ http://edureka.com/topic/ http://edureka.com/topic/cars/ http://edureka.com/topic/questions/
I want a php function to make the output like
edureka.com edureka.com/topic/ edureka.com/topic/cars/ edureka.com/topic/questions/
Hello @kartik,
Use:
$url = preg_replace("(^https?://)", "", $url );
This removes either http:// or https://
Hope it helps!!
Hello @kartik, Set posts_per_page parameter in args to ...READ MORE
Hello @kartik, In SQL Server, use MERGE MERGE INTO YourTable ...READ MORE
Hello @kartik, You need ImageMagick and GhostScript <?php $im = new imagick('file.pdf[0]'); $im->setImageFormat('jpg'); header('Content-Type: image/jpeg'); echo ...READ MORE
Hello @kartik, This is possible in HTML5. Example (PHP ...READ MORE
Hey @kartik, First you have to go to ...READ MORE
Named route is used to give specific ...READ MORE
Hello, This is simple you just need to ...READ MORE
Hey @kartik, Named routing is another amazing feature of ...READ MORE
Hello @kartik, The user-contributed section in the manual ...READ MORE
Hello @kartik, We setup wildcard DNS like they ...READ MORE
OR
At least 1 upper-case and 1 lower-case letter
Minimum 8 characters and Maximum 50 characters
Already have an account? Sign in.