444444444444

Hình ảnh
Câu1: Đâu là năm sinh năm mất của tác giả Trần Hữu Thung? 2023 1923 - 1998 1923 - 1997 1923 - 1999 Phương pháp giải : Đọc phần giới thiệu trang 15 hoặc tham khảo qua sách báo, internet Lời giải chi tiết : Trần Hữu Thung sinh năm 1923, mất năm 1999 Câu 2: Tác giả Trần Hữu Thung quê ở đâu? Thanh Hóa Nghệ An Thanh Hóa Thừa Thiên - Huế Phương pháp giải : Đọc phần giới thiệu trang 15 hoặc tham khảo qua sách báo, internet Lời giải chi tiết : Trần Hữu Thung quê ở Diễn Minh, Diễn Châu, Nghệ An Câu 3: Trần Hữu Thung sáng tác trong thời kì kháng chiến chống? Đế quốc Mĩ Phát xít Nhật Quân Nguyên-Mông Thực dân Pháp Câu 4: Trần Hữu Thung xuất thân trong gia đình thuộc tầng lớp nào? Qúy tộc Tri thức nghèo Nho học Nông dân Câu 5: Con hãy chọn những đáp án đúng (Được chọn nhiều đáp án) Đặc điểm thơ của Trần Hữu Thung như thế nào? Mộc mạc, dân dã. Chân chấ...

How to Make a Counter by Sothink SWF Quicker

Do you want to know how many visitors surfed on your website? I guess your answer is yes. But how to do and which tool can create such a counter? Now, I will solve all the problems and show you the steps to create a counter. 


Here, I will make this visit counter by Sothink SWF Quicker. Sothink SWF Quicker is a Flash editor to make Flash-based applications for website. It can create Flash games, Flash videos, interactive animations, text effects, slide shows, etc. By following the steps, you will get the counter like this:




Let’s begin to learn how to make counter:

Prepared Work and the Softwares Have Been Used: 


Steps: 

Step One: Make Background Image 
  • Launch Sothink SWF Quicker and you will see the above screenshot. Click the canvas, and then set the canvas size in the "Properties" panel.


  • Import an image (Get the 1.jpg from zip file). Right click the empty area in the "Library" panel, and choose the option "Import…" from the context-menu.

     
  • Drag this image to the canvas, and adjust its position, size, etc in the "Transform" panel. You will see the frame 1 changes into keyframe from blank keyframe in layer 1.


     
  • Copy the image, and paste it into the canvas. Choose this image, and set its properties in the "Transform" panel.

    7.GIF

     
  • Make sure the background image always showing. We insert the keyframe in the frame 40.

     


Step Two: Add Text and Write ActionScript for Them 
  • Add a new layer by clicking the button (see figure), and then add text on it.


     
  • Choose the tool "Text" in the "Tools" panel. And drag a rectangle on the canvas, input the text "Count" in it. You can set the text properties in the below "Properties" panel.


     
  • Still choose the tool "Text" in the "Tools" panel. And drag another rectangle on the canvas, enter the "Properties" panel, set Type as "Dynamic" and Var as "count". You will see the frame 1 changes into keyframe from blank keyframe in layer 2.

  • Select the frame 2, and right-click to choose "Convert to Keyframe" from context-menu.



     
  • Select the frame 40, and right-click to choose "Insert Keyframe" from context-menu.


  • The timeline will display like this:


     
  • Choose the frame 1 in the layer 2, and enter the "Action" panel, input the below ActionScript:

    this.loadVariables("count.php?num="+random(99));



    Note: count.php should be the same name with your PHP page.

     
  • Choose the frame 2 in the layer 2, and enter the "Action" panel, input the below ActionScript:

    this.loadVariables("count.txt?num="+random(999));



     
  • Choose the frame 40 in the layer 2, and enter the "Action" panel, input the below ActionScript:



    gotoAndPlay(2);



Step Three: Export the Flash Counter 
  • After all the work is done, you can click "Export" button to export this Flash counter.


     
  • Choose a directory to save this SWF file, and name it "count.swf".

     
Step Four: Make a PHP Page

  • Open your Dreamweaver, and create a PHP page named as "count.php".

     
  • Enter the "Code" view, and remove all the code in it. You need to paste the below code into the Dreamweaver.

    <?php
    $count = file_get_contents("count.txt");
    $count = explode("=", $count);
    $count[1] = $count[1]+1;
    $file = fopen("count.txt", "w+");
    fwrite($file, "count=".$count[1]);
    fclose($file);
    print "count=".$count[1];
    ?>



Step Five: Make an HTML Page 

  • Open your Dreamweaver, and create a PHP page named as "c.html".

     
  • In the "Design" view, click "Insert > Media > Flash" to insert the “count.swf” into the page.


  • After inserting the Flash, the result will be like this:



At last, upload all the files include count.swf, count.php, and c.html to the server, which PHP is installed on it (make sure these files are saved in one folder), to test if the counter works well.
Hope this tutorial can help you. 

Nhận xét

Bài đăng phổ biến từ blog này

How to Edit SWF file

Create a Button

Edit texts - Flash Decompiler Trillix for Windows