このページのトップへ
Hide and Show an Image

Hide and Show an Image

Show and hide an image according to the clicked button.

中級.png

初心者

9K

出版された:

February 23, 2020

酒を楽しむ少女

によって

アンカー 1
開発者を雇う

説明例

In this example we use two buttons in order to show and hide an image.

コード例

タブ1

.

タブ2

.

タブ3

.

このコードによる解決は複雑になる可能性がある。

どのように構築したか

ページ要素


In our site we added the following page elements:

  • An image

  • Two buttons, one with the ID "showButton" and one with the ID “hideButton”.


コード


In the onReady() function we added two event handlers, one for each button.

When clicking the hide button the image is hidden and when clicking the show button the image is shown again.

使用したAPI

コード以外の例。

関連記事

記事リンク

開発者を雇う

Veloソリューションは強力なツールですが、自力で構築するのは困難です。経験豊富なVelo開発会社に構築をお任せください。

関連例

これは役に立ったか?

はい

|

いいえ

ご意見ありがとう!

エレメントの非表示と表示

エレメントの非表示と表示

ユーザーのインタラクションに応じて要素を隠したり表示したりする。

中級.png

中級

崩壊要素

崩壊要素

要素グループの折りたたみと展開。

中級.png

初心者

Image and Text Animation

Image and Text Animation

Use wix-animations API to animate images and text.

中級.png

中級

アンカー2
ページ下