HomeController.php

public function getFrontFacebook()
{
    $domain = $_SERVER['SERVER_NAME'];
    $user = User::where('domain', $domain)->first();

    return view('soulfy.facebook', ['user' => $user]);

}

How to hide .content-placeholder on the first load? Since the load js does not function any longer after the soulfy.facebook page open.

How to fix this script and place it on soulfy.facebook.

$(".content-placeholder").hide();

For pure java script :

var placeholderVal;
function hidePlaceholder(){
     placeholderVal = document.getElementById("inputId").placeholder;
     document.getElementById("inputId").placeholder = "";
}
function showPlaceholder(){
     document.getElementById("inputId").placeholder = placeholderVal;

If you are using Jquery:

$("#btn-hide").click(function () {
            $("[name=test]").removeAttr("placeholder");
      });

      $("#btn-show").click(function () {
            $("[name=test]").attr("placeholder","testing");

  });
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.