search
HomeBackend DevelopmentPHP Tutorial各位大大,帮我看看fancybox的问题

<link rel="stylesheet" type="text/css" href="css/fancybox.css" /><link rel="stylesheet" type="text/css" href="css/css.css" /><script src="js/jquery.js" type="text/javascript"></script><script src="js/i18n/grid.locale-cn.js" type="text/javascript"></script><script src="js/jquery.fancybox.js" type="text/javascript"></script> <script src='js/jquery-1.4.2.min.js' type='text/javascript'></script>              <script type='text/javascript' src='js/picnet.table.filter.min.js'></script>   <script src="js/jquery.message.js" type="text/javascript"></script><style type="text/css"> * {  padding:0;  margin:0; } body {	font-family:verdana;	font-size:12px;	margin-left: 0px;	margin-top: 0px; } .content {  width:1100px;  margin:20px 10px; } .content h1 {  font-family:'??';  font-size:18px;  padding-bottom:5px; } table {  width:100%; } th, td {  padding:6px 0;  text-align:center; } th {  background-color:#accdf4;  color:#ffffff; }  tr {  background-color:#FFFFFE; }  .odd {  background-color:#FFFAFF; }  .highlight {  background-color:#E0E0E0;}.STYLE3 {font-size: 14px}</style><script type="text/javascript"> //?jsclass function addClass(element, value) {  if(!element.className) {   element.className = value;   } else {   element.className += " "+value;  } }  function stripeTable() {  var tables = document.getElementsByTagName("table");   for(var i=0; i<tables.length; i++) {   var rows = document.getElementsByTagName("tr");   for(var j=0; j<rows.length; j++) {    if(j%2 == 0) {     addClass(rows[j], "odd");      //rows[j].setAttribute("class", "odd");    }   }  } }  //??? function highlightRows() {  var rows = document.getElementsByTagName("tr");  for(var i=0; i<rows.length; i++) {   rows[i].oldClassName = rows[i].className;    rows[i].onmouseover = function() {    addClass(this, "highlight");    }   rows[i].onmouseout = function() {    this.className = this.oldClassName;    }  } }  window.onload = function() {  stripeTable();  highlightRows(); }            $(document).ready(function() {            //  Randomly Create Data Rows                   // Initialise Plugin            var options1 = {                additionalFilterTriggers: [],                clearFiltersControls: [],                matchingRow: function(state, tr, textTokens) {                  if (!state || !state.id) {                    return true;                  }                  var child = tr.children('td:eq(2)');                  if (!child) return true;                  var val = child.text();                  switch (state.id) {                  case 'onlyyes':                    return state.value !== true || val === 'yes';                  case 'onlyno':                    return state.value !== true || val === 'no';                  default:                    return true;                  }                }            };            $('#demotable1').tableFilter(options1);                 var grid2 = $('#demotable2');           var options2 = {                                   filteringRows: function(filterStates) {                grid2.addClass('filtering');              },              filteredRows: function(filterStates) {                grid2.removeClass('filtering');                setRowCountOnGrid2();              }            };                       function setRowCountOnGrid2() {              var rowcount = grid2.find('tbody tr:not(:hidden)').length;              $('#rowcount').text('(Rows ' + rowcount + ')');            }            grid2.tableFilter(options2); // No additional filters                  setRowCountOnGrid2();        });</script><script type="text/javascript">function more(value){  $.fancybox({			'type':'ajax',			'href':'sale_detailed.php?value='+value		});}  $(document).ready(function() {	$(".various").fancybox({		maxWidth	: 800,		maxHeight	: 600,		fitToView	: false,		width		: '70%',		height		: '70%',		autoSize	: false,		closeClick	: false,		openEffect	: 'none',		closeEffect	: 'none'	});});</script><h2 id="销售订单列表">销售订单列表</h2><form id="add_form" action="sale_list.php?page=1" method="GET"><div class="content"><?PHPinclude_once ("page.class.php");include_once ("conn.php");$pageSize=50; if(empty($_GET['page'])) { $spage=1; } else { $spage=$_GET['page']; }$start=$spage*$pageSize-$pageSize;if(!empty($_GET['findtext'])){$findtext=$_GET['findtext'];$findtype=$_GET['findtype'];$findsql="AND `".$findtype."`='".$findtext."'";}else{$findsql='';}$result = mysql_query("SELECT COUNT(*) AS count FROM `sale_orders` WHERE `number`>0 ".$findsql);		$row = mysql_fetch_array($result, MYSQL_ASSOC);		$total= $row['count'];$SQL = "SELECT * FROM `sale_orders` WHERE `number`>0 ".$findsql." LIMIT $start , $pageSize";$result = mysql_query($SQL);$url=$_SERVER["REQUEST_URI"];		pageft($total,$pageSize,1,1,1,5,$url);?><a onclick="more(234234)">单引号Ajax</a><div id="opt">        <div id="query">                           <label></label>  						<select name="findtype">		   <option value="order_id" selected="selected" >订单号</option>		   <option value="sku" >订单SKU</option>          </select>            <input type="text" class="input" id="sale_text" name="findtext"  />            <input type="submit"  class="btn" id="find_btn" value="查 询" />			        </div>  </div>  <table width="195%" cellspacing="1" bgcolor="#0093C4" id='demotable1'>   <thead>     <tr>       <th width="17%"><span class="STYLE3">订单号</span></th>       <th width="13%" class="STYLE3">客户姓名</th>       <th width="15%" class="STYLE3">订单SKU</th>       <th width="42%" class="STYLE3">产品名称</th>       <th width="6%" class="STYLE3">购买数量</th>       <th width="7%" class="STYLE3">订单状态</th>     </tr>   </thead>   <tbody>     <?PHP  while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {  ?>     <tr>       <td><a onclick="more(<?PHP echo $row['order_item_id'];?>)" href='sale_detailed.php?value=<?PHP echo $row['order_item_id']; ?>'><?PHP echo $row['order_id']; ?></a></td>       <td><?PHP echo $row['buyer_name']; ?></td>             <td><?PHP echo $row['sku']; ?></td>       <td><?PHP	    $prna=$row['product_name']; 		if(strlen($prna)>20)		{		$prna=mb_substr($prna,0,40,'utf-8')."...."; 		echo $prna;		}		else		{		echo $prna;		}	   	   	   ?></td>       <td><?PHP echo $row['quantity_purchased']; ?></td>	    <td><?PHP 		$shipments=$row['shipments'];		switch ($shipments){case "0":    echo "未发货";  break;case "1": echo "已发货";  break;  case "2": echo "已取消";  break;}				  ?></td>     </tr>     <?PHP  }  ?>   </tbody> </table></div></form><div class="digg"><?php echo $pagenav;?></div>


$(".various").fancybox({

$.fancybox({
以上语句报错,请问怎么样写可以弹出fancybox窗口


回复讨论(解决方案)

贴出错误代码?

报什么错?没用过jquery.fancybox, 是不是用法用错了

TypeError: $(...).fancybox is not a function
[在此错误处中断] 

closeEffect : 'none'

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Working with Flash Session Data in LaravelWorking with Flash Session Data in LaravelMar 12, 2025 pm 05:08 PM

Laravel simplifies handling temporary session data using its intuitive flash methods. This is perfect for displaying brief messages, alerts, or notifications within your application. Data persists only for the subsequent request by default: $request-

cURL in PHP: How to Use the PHP cURL Extension in REST APIscURL in PHP: How to Use the PHP cURL Extension in REST APIsMar 14, 2025 am 11:42 AM

The PHP Client URL (cURL) extension is a powerful tool for developers, enabling seamless interaction with remote servers and REST APIs. By leveraging libcurl, a well-respected multi-protocol file transfer library, PHP cURL facilitates efficient execution of various network protocols, including HTTP, HTTPS, and FTP. This extension offers granular control over HTTP requests, supports multiple concurrent operations, and provides built-in security features.

Simplified HTTP Response Mocking in Laravel TestsSimplified HTTP Response Mocking in Laravel TestsMar 12, 2025 pm 05:09 PM

Laravel provides concise HTTP response simulation syntax, simplifying HTTP interaction testing. This approach significantly reduces code redundancy while making your test simulation more intuitive. The basic implementation provides a variety of response type shortcuts: use Illuminate\Support\Facades\Http; Http::fake([ 'google.com' => 'Hello World', 'github.com' => ['foo' => 'bar'], 'forge.laravel.com' =>

12 Best PHP Chat Scripts on CodeCanyon12 Best PHP Chat Scripts on CodeCanyonMar 13, 2025 pm 12:08 PM

Do you want to provide real-time, instant solutions to your customers' most pressing problems? Live chat lets you have real-time conversations with customers and resolve their problems instantly. It allows you to provide faster service to your custom

Explain the concept of late static binding in PHP.Explain the concept of late static binding in PHP.Mar 21, 2025 pm 01:33 PM

Article discusses late static binding (LSB) in PHP, introduced in PHP 5.3, allowing runtime resolution of static method calls for more flexible inheritance.Main issue: LSB vs. traditional polymorphism; LSB's practical applications and potential perfo

PHP Logging: Best Practices for PHP Log AnalysisPHP Logging: Best Practices for PHP Log AnalysisMar 10, 2025 pm 02:32 PM

PHP logging is essential for monitoring and debugging web applications, as well as capturing critical events, errors, and runtime behavior. It provides valuable insights into system performance, helps identify issues, and supports faster troubleshoot

Discover File Downloads in Laravel with Storage::downloadDiscover File Downloads in Laravel with Storage::downloadMar 06, 2025 am 02:22 AM

The Storage::download method of the Laravel framework provides a concise API for safely handling file downloads while managing abstractions of file storage. Here is an example of using Storage::download() in the example controller:

HTTP Method Verification in LaravelHTTP Method Verification in LaravelMar 05, 2025 pm 04:14 PM

Laravel simplifies HTTP verb handling in incoming requests, streamlining diverse operation management within your applications. The method() and isMethod() methods efficiently identify and validate request types. This feature is crucial for building

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

Hot Tools

SublimeText3 Linux new version

SublimeText3 Linux new version

SublimeText3 Linux latest version

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

WebStorm Mac version

WebStorm Mac version

Useful JavaScript development tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor