LoginSignup
0
0

More than 3 years have passed since last update.

javascriptのブックマークレットが動作しない

Last updated at Posted at 2019-07-08

下記のような形に、クラスの値を変更するためのブックマークレットを作成したいと考えております。

 .result_headline {
    display: block!important;
}

 #resultBox{
    height:1000px!important;
}

試したのは、以下のコードです。
ブックマーク内の記述を下記に致しました。

javascript:(function show(){
        var e = document.getElementsByClassName("result_headline");
        e.style.display = "block";
    })

 #resultBoxの場合、getElementById
 を使うことまでは、分かりましたが、実際の記述の仕方は分かりませんでした。

お詳しい方に、アドバイスなど頂けますと幸いです。
何卒どうぞよろしくお願い致します。

0
0
8

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0