AjaxSearch - MODX Community Forums https://forums.modx.com/board/?board=94 <![CDATA[How to Use Advance Search in Modx Revolution?]]> https://forums.modx.com/thread/100848/how-to-use-advance-search-in-modx-revolution#dis-post-546261 https://forums.modx.com/thread/100848/how-to-use-advance-search-in-modx-revolution#dis-post-546261 Tue, 08 Nov 2016 12:20:27 +0000 https://forums.modx.com/thread/100848/how-to-use-advance-search-in-modx-revolution#dis-post-546261 <![CDATA[Highlighting words only in search results ?]]> https://forums.modx.com/thread/97762/highlighting-words-only-in-search-results#dis-post-529633
Is there a way to make the "Highlight Search" plugin highlighting words only in the search results but not in the linked pages?

When having &highlightResult=`1`, the matching words in both AjaxSearch results and linked pages are highlighted.

Thanks.]]>
https://forums.modx.com/thread/97762/highlighting-words-only-in-search-results#dis-post-529633 Fri, 07 Aug 2015 07:36:29 +0000 https://forums.modx.com/thread/97762/highlighting-words-only-in-search-results#dis-post-529633
<![CDATA[Ajax search with getting results immediately when the search term is entered]]> https://forums.modx.com/thread/92196/ajax-search-with-getting-results-immediately-when-the-search-term-is-entered#dis-post-529632 http://steambuy.com/
You start to enter the name of some game in the search box, and you immediately get styled search results right under this search box.]]>
https://forums.modx.com/thread/92196/ajax-search-with-getting-results-immediately-when-the-search-term-is-entered#dis-post-529632 Fri, 07 Aug 2015 07:28:38 +0000 https://forums.modx.com/thread/92196/ajax-search-with-getting-results-immediately-when-the-search-term-is-entered#dis-post-529632
<![CDATA[Avoid path to images in AjaxSearch results ?]]> https://forums.modx.com/thread/97761/avoid-path-to-images-in-ajaxsearch-results#dis-post-528668
I have the issue that images in named folders pollute the results from AjaxSearch.

Example
In the html code of some page is some path to an image like:
assets/images/rugby/some-rugbyman.jpg

I don't want that page being returned on the basis of the image path when searching for "rugby". However, if the page contains the word "rugby" in its text, I want it to be returned. Of course, this is for all search expressions and not only "rugby".

I assume I need some Ditto filtering with a regular expression or equivalent. Some filtering that would exclude searching the word when in a chain between double quotes and starting with "assets".

Is there a way to do it?]]>
https://forums.modx.com/thread/97761/avoid-path-to-images-in-ajaxsearch-results#dis-post-528668 Tue, 21 Jul 2015 11:28:08 +0000 https://forums.modx.com/thread/97761/avoid-path-to-images-in-ajaxsearch-results#dis-post-528668
<![CDATA[problem with &tplPaging for ajaxSearch]]> https://forums.modx.com/thread/48441/problem-with-tplpaging-for-ajaxsearch#dis-post-527541
I'm working with modX Evolution 1.0.5

I'm probably to tired, but I don't know how to make it work : I just want to use my own tpl for the ajaxsearch pagination.

My code in ajaxsearch landing page
[!AjaxSearch? &ajaxSearch=`0` &showResults=`1` &showInputForm=`0` &showPagingAlways=`1` &pagingType=`0` &grabMax=`10` &grpResultsDef=`0` &tplPaging=`searchPagingTpl` !]


My chunk 'searchPagingTpl'
[+as.tpl:is=`paging`:then=`
  <div class="ajaxSearch_paging">
    <span>[+as.pagingText+]</span>
    [+as.pagingLinks+]
  </div>
`+]
[+as.tpl:is=`pagingLinks`:then=`
  <a href="[+as.pagingLink+]">[+as.pagingText+]</a>
`+]
[+as.tpl:is=`pagingLinksCurrent`:then=`
  <span class="ajaxSearch_currentPage">[+as.pagingText+]</span>
`+]


But modx still use the default tpl
[+as.tpl:is=`paging`:then=`
  <span class="ajaxSearch_paging">
    [+as.pagingText+]
    [+as.pagingLinks+]
  </span>
`+]
[+as.tpl:is=`pagingLinks`:then=`
  <a href="[+as.pagingLink+]">[+as.pagingText+]</a>[+as.pagingSeparator+]
`+]
[+as.tpl:is=`pagingLinksCurrent`:then=`
  <span class="ajaxSearch_currentPage">[+as.pagingText+]</span>[+as.pagingSeparator+]
`+]


What am i missing ?

Thanks for your help (and sorry for my english) smiley

]]>
https://forums.modx.com/thread/48441/problem-with-tplpaging-for-ajaxsearch#dis-post-527541 Sat, 27 Jun 2015 11:02:28 +0000 https://forums.modx.com/thread/48441/problem-with-tplpaging-for-ajaxsearch#dis-post-527541
<![CDATA[ [SOLVED] Ajaxsearch with TVs]]> https://forums.modx.com/thread/96539/solved-ajaxsearch-with-tvs#dis-post-522520
I have run the following snippet:

[!AjaxSearch? &ajaxSearch=`0` &ajaxSearch=`0` &showIntro=`0` &showResults=`0` &landingPage=`9` &advSearch=`allwords`!]


And my landing page has this snippet call:

[!AjaxSearch? &ajaxSearch=`0` &parents=`4` &tvPhx=`legoImages` &whereSearch=`content` &order=`pagetitle` &extract=`2:longtitle,introtext` &showPagingAlways=`1`!]


My TV has a value of `image` and is named legoImages. The results when called return a pagetitle and summary, but the image appears as a tiny empty square. Looking at the page source it shows
<img src="" height="" />


I have amended result.tpl to:

<div>
<a href="[+as.resultLink+]" title="[+as.longtitle+]">[+as.pagetitle+]</a>
<div>
<img src="[+as.LegoImages+]" height="[+as.legoImages:imgmaxheight=`120`+]" />
</div>
[+as.extractShow:is=`1`:then=`
<div><p>[+as.extract+]</p></div>
`+]
[+as.breadcrumbsShow:is=`1`:then=`
<span>[+as.breadcrumbs+]</span>
`+]
</div>


My search results dont appear to pull the image in? Can anyone see any obvious mistakes?
Regards,
SB]]>
https://forums.modx.com/thread/96539/solved-ajaxsearch-with-tvs#dis-post-522520 Fri, 13 Mar 2015 06:31:51 +0000 https://forums.modx.com/thread/96539/solved-ajaxsearch-with-tvs#dis-post-522520
<![CDATA[ajaxSearch: example to search custom tables]]> https://forums.modx.com/thread/91849/ajaxsearch-example-to-search-custom-tables#dis-post-501827 https://forums.modx.com/thread/91849/ajaxsearch-example-to-search-custom-tables#dis-post-501827 Mon, 30 Jun 2014 10:56:50 +0000 https://forums.modx.com/thread/91849/ajaxsearch-example-to-search-custom-tables#dis-post-501827 <![CDATA[How to speed up AjaxSearch with a site that contains 2,000+ pages?]]> https://forums.modx.com/thread/71638/how-to-speed-up-ajaxsearch-with-a-site-that-contains-2-000-pages#dis-post-497897
We are currently trying to implement AjaxSearch on a MODx Evolution site which has over 2,300 documents, we would like the search to work across the content and TV, each page has around 7 TV's.

When we search at the moment it is really slow, I suspect because it is doing a lot of db queries at the same time, when we limit the search to content only it runs quick.

Any tips on how to speed up the AjaxSearch? I'm currently thinking that I might have to run a cron job each day which GROUP_CONCACT the TV's for each page and adds them to the MODx document description, comma separated but I was wondering if there is an out of the box way to speed boost this?

Thanks Aaron]]>
https://forums.modx.com/thread/71638/how-to-speed-up-ajaxsearch-with-a-site-that-contains-2-000-pages#dis-post-497897 Tue, 13 May 2014 02:39:57 +0000 https://forums.modx.com/thread/71638/how-to-speed-up-ajaxsearch-with-a-site-that-contains-2-000-pages#dis-post-497897
<![CDATA[How to search for exact phrase only ? (AjaxSearch 1.9.1 / MODX Evo 1.0.3)]]> https://forums.modx.com/thread/89262/how-to-search-for-exact-phrase-only-ajaxsearch-1-9-1-modx-evo-1-0-3#dis-post-490877
I'm using the 1.9.1 version of AjaxSearch on a site powered by MODX 1.0.3.

For the &advSearch parameter, none of the "allwords" or "exactphrase" values work. I read that "allwords" was working with AjaxSearch 1.9.2.

Was "exactphrase" implemented in later versions and what is the compatibility with MODX 1.0.3 ?

Thanks.]]>
https://forums.modx.com/thread/89262/how-to-search-for-exact-phrase-only-ajaxsearch-1-9-1-modx-evo-1-0-3#dis-post-490877 Sat, 22 Feb 2014 12:54:48 +0000 https://forums.modx.com/thread/89262/how-to-search-for-exact-phrase-only-ajaxsearch-1-9-1-modx-evo-1-0-3#dis-post-490877
<![CDATA[AjaxSearch Version obsolete: just with Internet Explorer???]]> https://forums.modx.com/thread/89170/ajaxsearch-version-obsolete-just-with-internet-explorer#dis-post-490329 I use AjaxSearch (1.9.3b) for a long time in a website. With Safari or Firefox no problems. With Internet Explorer Version 10.0.9200.16798 i get the following message:

AjaxSearch version obsolete. Empty your browser cache and check the version of AjaxSearch-jQuery.js file.

What is the problem here? Thanks for help.

Markus]]>
https://forums.modx.com/thread/89170/ajaxsearch-version-obsolete-just-with-internet-explorer#dis-post-490329 Mon, 17 Feb 2014 03:48:43 +0000 https://forums.modx.com/thread/89170/ajaxsearch-version-obsolete-just-with-internet-explorer#dis-post-490329
<![CDATA[Ajaxsearch Strict Validation]]> https://forums.modx.com/thread/47865/ajaxsearch-strict-validation?page=2#dis-post-486145 https://forums.modx.com/thread/47865/ajaxsearch-strict-validation?page=2#dis-post-486145 Sun, 29 Dec 2013 08:07:52 +0000 https://forums.modx.com/thread/47865/ajaxsearch-strict-validation?page=2#dis-post-486145 <![CDATA[AjaxSearch with custom input criteria of &tplInput seems got issues with mysql values]]> https://forums.modx.com/thread/88295/ajaxsearch-with-custom-input-criteria-of-tplinput-seems-got-issues-with-mysql-values#dis-post-485888
and when I search the DB like:
<code>
SELECT *
FROM `modx_site_tmplvar_contentvalues`
WHERE value = '10,001-20,000'
LIMIT 0 , 30
</code>
then mysqlphpadmin returns: Showing rows 0 - 29 (324 total, Query took 0.0052 sec)

But here is a more complex sql query I logged from ajaxSearch snippet:
<code>
SELECT sc.id, sc.pagetitle, sc.longtitle, sc.description, sc.alias, sc.introtext, sc.template, sc.menutitle, sc.content, sc.publishedon, GROUP_CONCAT( DISTINCT CAST(ntv.id AS CHAR) SEPARATOR "," ) AS tv_id, GROUP_CONCAT( DISTINCT ntv.value SEPARATOR "," ) AS tv_value, ntv1.value AS property, ntv2.value AS bedrooms1, ntv3.value AS condo, ntv4.value AS condorentprice, ntv5.value AS condosaleprice, ntv6.value AS location, ntv7.value AS houserentprice, ntv8.value AS housesaleprice FROM `modx_site_content` sc LEFT JOIN( SELECT DISTINCT tv.id, tv.value, tv.contentid FROM `modx_site_tmplvar_contentvalues` tv ) AS ntv ON sc.id = ntv.contentid LEFT JOIN( SELECT DISTINCT tv1.contentid , tv1.value FROM `modx_site_tmplvar_contentvalues` tv1 WHERE tv1.tmplvarid = '18' ) AS ntv1 ON sc.id = ntv1.contentid LEFT JOIN( SELECT DISTINCT tv2.contentid , tv2.value FROM `modx_site_tmplvar_contentvalues` tv2 WHERE tv2.tmplvarid = '11' ) AS ntv2 ON sc.id = ntv2.contentid LEFT JOIN( SELECT DISTINCT tv3.contentid , tv3.value FROM `modx_site_tmplvar_contentvalues` tv3 WHERE tv3.tmplvarid = '15' ) AS ntv3 ON sc.id = ntv3.contentid LEFT JOIN( SELECT DISTINCT tv4.contentid , tv4.value FROM `modx_site_tmplvar_contentvalues` tv4 WHERE tv4.tmplvarid = '22' ) AS ntv4 ON sc.id = ntv4.contentid LEFT JOIN( SELECT DISTINCT tv5.contentid , tv5.value FROM `modx_site_tmplvar_contentvalues` tv5 WHERE tv5.tmplvarid = '23' ) AS ntv5 ON sc.id = ntv5.contentid LEFT JOIN( SELECT DISTINCT tv6.contentid , tv6.value FROM `modx_site_tmplvar_contentvalues` tv6 WHERE tv6.tmplvarid = '14' ) AS ntv6 ON sc.id = ntv6.contentid LEFT JOIN( SELECT DISTINCT tv7.contentid , tv7.value FROM `modx_site_tmplvar_contentvalues` tv7 WHERE tv7.tmplvarid = '21' ) AS ntv7 ON sc.id = ntv7.contentid LEFT JOIN( SELECT DISTINCT tv8.contentid , tv8.value FROM `modx_site_tmplvar_contentvalues` tv8 WHERE tv8.tmplvarid = '24' ) AS ntv8 ON sc.id = ntv8.contentid WHERE ((sc.id IN (3,464,33,477,478,479,480,7,136,138,161,847,15,551,67,10,19,9,1620,12,300,364,11,646,647,648,649,650,651,652,653,632,633,634,635,986,2,1069,1070,1152,1153,1094,27,82,25,22,26,604,1035,1802,1920,1877,1906,1982,872,955,1204,1696,400,1933,1977,273,112,288,391,1943,1332,1390,1346,24,192,190,838,128,142,143,157,169,205,234,278,312,331,455,577,349,355,419,420,517,554,555,605,679,689,707,732,752,1990,820,855,856,861,868,873,899,1829,989,1033,1203,1305,1331,1333,1377,1460,1591,1592,1617,1680,1852,1019,1886,1055,1493,1792,1903,1894,334,1356,1396,1397,1401,1494,1586,1853,1956,1960,1986,21,127,1276,602,706,809,990,1214,1265,1375,1439,1478,1560,1561,1613,1871,1880,1908,1955,1981,1636,340,519,912,939,1267,1373,1649,1677,1808,1630,1500,1515,1884,1339,1365,1809,1909,1952,660,674,1262,1340,1726,1799,1635,1638,1642,174,852,953,1730,1827,1854,1945,1641,1675,1719,1749,1504,1839,1932,1652,1918,1927,954,1352,844,970,240,805,1548,1942,784,1769,237,443,836,1385,813,1969,1976,803,357,528,1431,430,173,520,81,356,523,343,213,228,231,95,132,318,267,271,30,755,823,798,1351,909,598,1148,1834,432,1056,1667,1741,1891,1557,1650,1558,1666,31,58,120,125,98,145,146,175,184,183,194,206,208,210,221,232,1404,394,261,270,272,274,1554,313,314,324,350,358,366,375,405,1374,429,437,439,450,458,476,486,490,496,505,512,518,533,539,550,1125,610,1133,1345,641,645,664,669,676,704,720,725,728,733,756,765,771,768,782,1520,788,814,854,860,863,913,915,927,929,1519,1452,979,983,996,1018,1031,1463,1053,1060,1122,1124,1141,1147,1175,1184,1207,1256,1264,1275,1304,1353,1367,1371,1391,1407,1427,1428,1469,1483,1486,1523,1573,1574,1578,1589,1721,1759,1779,1805,1879,1605,1904,212,1030,1061,1145,1247,1451,1458,1807,1910,1915,1992,1980,28,113,248,1581,862,1140,1269,1291,1424,1482,1928,259,333,1575,1501,1885,1260,1369,1550,1555,1603,1611,1616,584,1513,1435,1569,1767,1778,1826,925,1925,330,407,1528,1698,1806,534,1665,1647,220,1115,1840,1921,1973,1961,227,1533,485,775,167,211,23,1780,235,229,524,332,402,414,217,1873,45,871,433,1098,85,1096,474,766,1526,1786,1238,1430,1717,207,310,311,155,133,103,163,182,269,209,214,219,225,257,258,260,262,275,277,279,316,341,342,373,389,422,426,493,499,508,527,570,609,1299,681,683,722,731,740,742,758,783,817,1437,867,875,876,945,951,1139,1208,1249,1261,1335,1336,1366,1379,1433,1496,1527,1544,1582,1663,1678,1697,1744,1801,265,1958,289,680,835,922,1194,1450,1570,1810,297,668,1473,1883,721,1596,1461,1546,1559,1456,1491,1643,1631,1567,1844,135,1529,1930,843,1624,494,885,529,760,532,637,640,667,1733,255,1743,491,778,131,1349,119,141,187,223,263,290,291,292,351,1475,497,501,542,560,580,746,753,799,839,883,895,921,928,956,1048,1085,1113,1246,1334,1347,1488,1614,1727,1117,1255,1784,1490,1521,975,1710,1368,1593,1543,1983,254,564,841,896,1860,488,1013,250,665,1708,670,293,353,368,369,396,440,226,245,694,699,296,359,365,435,451,1723,483,489,561,565,594,606,657,666,684,749,785,1041,857,974,1036,1342,1481,1492,1707,1747,1787,1659,829,1306,1422,1585,1704,1734,1768,750,1126,1676,1712,1859,1509,692,686,1916,1691,998,1384,1705,1738,1923,824,825,178,444,687,1163,1824,1855,1288,1987,139,1692,325,1938,710,1545,1949,1968,1644,682,575,547,559,718,786,830,870,898,908,385,586,1300,425,544,387,540,1311,247,691,804,961,339,587,1324,384,386,591,152,149,153,154,171,170,582,965,552,1322,1325,1489,1326,1327,1328,1625,1896,2003,942,980,999,1100,1221,1610,1795,1797,1815,1989,1686,302,711,1997,935,1024,1028,1455,1487,1572,1656,1757,1793,1796,1870,1905,1640,304,1510,1999,878,1001,1084,1143,1303,1329,1388,1556,1825,1864,2001,466,937,1360,1830,286,914,1026,1645,994,743,1381,831,1689,626,1330,243,463,581,390,1032,621,1416,1900,1302,1361,1756,1798,1898,1902,1292,1758,417,203,242,393,266,285,287,299,306,328,363,411,413,446,449,456,815,569,572,576,818,596,620,631,713,764,734,762,793,797,812,802,840,1626,880,890,893,910,917,984,1755,1045,1059,1363,1216,1323,1348,1376,1503,1505,1600,1606,1607,1654,1828,1775,1800,1865,1971,614,1627,1857,1102,1480,1495,1669,1670,1816,1820,1935,1890,323,1998,1058,1192,1243,1399,1534,1549,1583,1599,1608,1684,1907,1964,1967,1979,1895,2004,1301,1419,1177,1602,1702,1736,1817,1841,1893,2000,1420,1604,1899,1051,307,1205,887,973,1160,1405,1539,1701,284,1819,1965,1629,658,964,1803,888,1023,1535,1536,1537,1594,1794,1818,1972,1648,737,1011,109,811,1861,1985,1897,600,982,678,1418,1966,727,1835,1919,588,1847,1843,116,303,599,1700,1729,1842,467,795,410,1089,256,1746,1522,1750,1764,1814,1912,1888,1387,1423,1683,1901,567,1400,1295,305,110,195,197,198,201,298,969,452,461,503,1628,537,545,556,558,608,611,736,716,726,745,754,761,779,789,791,796,849,1421,865,892,931,933,938,960,968,1004,1000,1027,1050,1067,1087,1088,1101,1297,1350,1402,1415,1471,1694,1651,1655,1688,1760,1763,1774,1776,1782,1811,1832,1833,1848,1863,1867,1869,507,1576,1716,1577,1882,1849,1850,1862,1924,1383,1477,1851,1929,673,780,822,1142,1309,700,1047,1639,643,1836,1846,1838,1845,1837,1831,428,469,563,553,612,317,1731,1485,894,1414,1823,1565,1728,1777,241,447,513,578,589,1448,618,902,1017,1052,1362,1118,1156,1623,1658,1785,2005,701,1621,1466,949,702,712,1673,348,346,693,1014,1564,1674,1144,1770,1939,1947,1984,1551,1714,1038,1129,1502,1468,1584,1601,1740,1994,1634,1178,1196,1657,1662,1685,1813,1821,1875,1995,1975,1083,1552,932,1082,1646,801,833,985,1553,1804,1382,1079,1313,1690,1914,832,418,252,879,816,1511,1978,698,627,1660,688,309,468,1293,301,268,372,416,457,470,471,482,504,506,1484,1106,597,603,622,624,625,628,630,672,703,1105,724,763,735,757,810,881,934,950,981,1037,1271,1298,1453,1609,1516,1524,1531,1753,1754,1773,1917,1146,1193,1532,1579,1661,1672,1681,1703,1732,1788,1856,1876,202,1963,891,1135,1359,1462,1598,1761,1812,1881,1988,1283,1671,616,1134,1310,1687,717,907,1138,1934,1946,1633,918,1822,1595,1913,601,1005,557,930,781,1937,1889,978,1950,1020,308,619,1951,926,1722,1713,864,137,613,322,977,792,1389,959,1789,1637,1109,196,1040,448,453,462,514,579,615,617,623,769,794,828,827,886,859,869,962,1006,1116,1136,1158,1180,1294,1321,1393,1541,1679,1745,1751,1752,1858,1866,1563,1653,1682,1108,1354,1668,1016,1137,337,327,1131,1112,1063,1417,326,1566,1121,118,338,399,541,677,971,1622,642,906,1440,1441,638,1312,1015,709,180,1465,1244,1392,1765,392,88,123,124,102,147,1008,383,398,404,521,583,767,897,1715,1289,1562,1922,1996,1464,1054,1064,1065,1066,1459,1911,1957,1892,294,1664,546,1103,1099,1149,1195,1215,1372,1406,1467,1479,1878,403,738,1235,1277,1344,1590,1612,730,1499,1438,1953,585,744,924,1003,1568,1991,39,853,1791,1772,842,44,475,509,1547,729,819,1002,739,36,408,78,77,719,59,1970,837,215,222,821,997,54,916,156,96,661,1742,280,68,319,526,522,376,381,473,571,946,38,51,191,87,117,126,99,105,114,177,379,423,244,395,695,320,321,378,380,401,406,409,465,487,498,659,663,715,882,988,991,993,995,1155,1169,1274,1378,1470,1571,1762,1615,1954,1959,943,1695,1154,1182,1206,1587,1107,1457,1270,1282,1411,1720,1597,1993,1436,759,1029,1245,1434,1540,1618,1632,193,249,1580,850,957,246,362,1530,1588,1699,1241,1737,1931,360,1766,107,510,747,150,675,1718,495,79,530,415,944,1043,1709,562,1781,295,160,166,168,281,233,671,920,696,1514,1748,188,218,535,230,236,32,377,481,445,639,397,434,777,1086,162,115,185,216,224,238,834,427,538,566,590,656,874,936,947,952,1049,1429,1114,1512,1268,1355,1408,1191,1412,923,1234,1724,903,1164,472,800,904,992,1183,1426,1735,1425,776,919,1218,1525,1926,354,787,851,1039,1042,543,1007,1012,253,536,549,592,806,1948,941,963,335,705,158,2002,186,866,1220,1706,251,382,424,1790,1150,568,442,367,436,111,1476,459,484,502,548,607,629,636,685,741,748,940,1044,1341,987,1872,905,1517,1010,655,1034,1711,1771,1454,1542,148,877,884,826,697,911,1009,790,1075,1076,1078,1077,1080,1071,1072,1073,1074,1081,1518,1307,1257,1394,1266,1258,1168,1410,1171,1172,1285,1170,1179,1197,1217,1263,1279,1224,1286,1202,1230,1251,1337,239,1380,1498,1062,1239,1250,1281,1166,1167,1188,1209,1222,1236,1318,1273,1284,1444,1248,1442,1211,1237,1223,1229,1242,1287,1201,1252,1253,1278,1162,1280,1319,1357,1409,1165,1198,1413,1212,1213,1343,1176,1445,1189,1219,1228,1200,1231,1240,1173,1174,1093,1187,1190,1259,1186,1232,1104,1497,1119,1210,1225,1025,1128,1296,1308,1386,1181,1364,1130,1272,1370,1157,967,1120,1199,1046,1739,1314,1398,1316,901,948,1395,1449,1432,1057,1358,972,1227,1226,1123,1446,1151,1447,1317,1127)) AND (sc.published=1) AND (sc.searchable=1) AND (sc.deleted=0) AND (sc.privateweb=0)) GROUP BY sc.id HAVING (FIND_IN_SET('House',property) AND FIND_IN_SET('0',bedrooms1) AND FIND_IN_SET('10,001 to 20,000',houserentprice)) ORDER BY sc.publishedon,sc.pagetitle
</code>

Nothing returned when I submit this into the same phpMyAdmin: MySQL returned an empty result set (i.e. zero rows). ( Query took 144.5573 sec )

The question is if there should be a better way to use anything for TV houserentprice instead of FIND_IN_SET('10,001 to 20,000',houserentprice) in HAVING mysql statement for getting the results?



For example the change with REPLACE in AND FIND_IN_SET('10,001to20,000',REPLACE(houserentprice, ' ', '')) didn't help.. Maybe the FIND_IN_SET has limitations or other..

I think the best way to fix is to improve FIND_IN_SET rather then edit ajaxsearch snippet's class (assets/snippets/ajaxSearch/classes/ajaxSearchRequest.class.inc.php line 59)]]>
https://forums.modx.com/thread/88295/ajaxsearch-with-custom-input-criteria-of-tplinput-seems-got-issues-with-mysql-values#dis-post-485888 Mon, 23 Dec 2013 10:39:26 +0000 https://forums.modx.com/thread/88295/ajaxsearch-with-custom-input-criteria-of-tplinput-seems-got-issues-with-mysql-values#dis-post-485888
<![CDATA[Need to move search box]]> https://forums.modx.com/thread/87202/need-to-move-search-box#dis-post-480435 https://forums.modx.com/thread/87202/need-to-move-search-box#dis-post-480435 Wed, 16 Oct 2013 05:38:38 +0000 https://forums.modx.com/thread/87202/need-to-move-search-box#dis-post-480435 <![CDATA[ [SOLVED] Need AjaxSearch results on separate page]]> https://forums.modx.com/thread/87119/solved-need-ajaxsearch-results-on-separate-page#dis-post-480419 http://modx.com/extras/package/ajaxsearch. I have created a landing page (resource) with the snippet call: [!AjaxSearch? &showInputForm=`0`&showResults=`1`&ajaxSearch=`1`!]

I also created a chunk for the Search and have the following there:

<div class="header_soc_search clearfix">
<div class="header_search">
[!AjaxSearch? &showResults=`1` &landingPage=`20` &showMoreResults=`1` &moreResultsPage=`20`!]
</div>

When I do a test search it generates results, but it shows up on the same page instead of going to a separate page. For example, if I'm on the home page and do a search, the results show there and push everything down below the header. I can't figure out what I'm doing wrong. I am a newbie so I'm still trying to figure out how all this works. Can someone please help me?]]>
https://forums.modx.com/thread/87119/solved-need-ajaxsearch-results-on-separate-page#dis-post-480419 Wed, 16 Oct 2013 01:21:39 +0000 https://forums.modx.com/thread/87119/solved-need-ajaxsearch-results-on-separate-page#dis-post-480419
<![CDATA[Ajaxsearch too slow, please help]]> https://forums.modx.com/thread/84668/ajaxsearch-too-slow-please-help#dis-post-469138
I have been running 2 Ajaxsearches on my site for a while now, and they return 2 images from pages that match the search criteria. The problem is it takes a while from the search query to view the search results. My calls are:

[!AjaxSearch? &ajaxSearch=`0` &showIntro=`0` &showResults=`0` &landingPage=`60` &advSearch=`allwords`!]


and

[!AjaxSearch? &asId=`as2` &ajaxSearch=`0` &showIntro=`0` &showResults=`0` &landingPage=`79`  &advSearch=`allwords`!]


The landing pages have this code:

[!AjaxSearch? &hideMenu=`0` &ajaxSearch=`0` &parents=`71,212,267,277,506,594,818` &withTV=`pagetitle` &tvPhx=`Factfile,Factfile2` &order=`pagetitle` &rank=`description:100,longtitle:10,pagetitle:10` &extract=`2:longtitle,introtext` &highlightResult=`0`!]


and

[!AjaxSearch? &asId=`as2` &hideMenu=`0` &ajaxSearch=`0` &parents=`71,81,211,212,256,267,277,294,376,500,506,577,594,818` &withTV=`pagetitle` &tvPhx=`Factfile,Factfile2` &order=`pagetitle`  &rank=`description:100,longtitle:10,pagetitle:10` &extract=`2:longtitle,introtext` &highlightResult=`0`!]


respectively. Can anyone see what might be slowing my search? Is it as simple as I am asking it to look into som many parent files?

Any help appreciated, thank you
Seb]]>
https://forums.modx.com/thread/84668/ajaxsearch-too-slow-please-help#dis-post-469138 Sat, 15 Jun 2013 10:24:01 +0000 https://forums.modx.com/thread/84668/ajaxsearch-too-slow-please-help#dis-post-469138
<![CDATA[AjaxSearch 1.9.3 for Evo available]]> https://forums.modx.com/thread/79628/ajaxsearch-1-9-3-for-evo-available#dis-post-438647 demo site.

No new functions are provided with this release. But for some issues it could be interested to upgrade your ajaxSearch release.

This release will be integrated in the next release of ClipperCMS.]]>
https://forums.modx.com/thread/79628/ajaxsearch-1-9-3-for-evo-available#dis-post-438647 Sat, 29 Sep 2012 05:28:32 +0000 https://forums.modx.com/thread/79628/ajaxsearch-1-9-3-for-evo-available#dis-post-438647
<![CDATA[Speed up search]]> https://forums.modx.com/thread/78643/speed-up-search#dis-post-433281 https://forums.modx.com/thread/78643/speed-up-search#dis-post-433281 Tue, 14 Aug 2012 11:19:12 +0000 https://forums.modx.com/thread/78643/speed-up-search#dis-post-433281 <![CDATA[Tabbed results]]> https://forums.modx.com/thread/78530/tabbed-results#dis-post-432899
So how would one produce tabbed grouped results, using jquery for the Ajax search?]]>
https://forums.modx.com/thread/78530/tabbed-results#dis-post-432899 Sat, 11 Aug 2012 05:31:43 +0000 https://forums.modx.com/thread/78530/tabbed-results#dis-post-432899
<![CDATA[Very Slow AjaxSearch]]> https://forums.modx.com/thread/77681/very-slow-ajaxsearch#dis-post-429817
Here is my AjaxSearch call:
[!AjaxSearch? &liveSearch=`1` &parents=`32,33,34,35`&depth=`1`&jscript=`jquery` &jsJquery=`assets/js/jquery-1.3.2.min.js` &debug=`3`!]


And my debug file:
http://pastebin.com/kW9NH2gG

It's taking an average of 45 seconds to return any results. I pared down the Array at the bottom of the debug file as it appears that it is grabbing a lot of the page content. Could this be slowing it down? How can I limit it to only specific TVs and ignoring page content? I tried using &whereSearch=`tv` but then it stopped returning any results.

Thanks for your help.]]>
https://forums.modx.com/thread/77681/very-slow-ajaxsearch#dis-post-429817 Fri, 13 Jul 2012 02:34:08 +0000 https://forums.modx.com/thread/77681/very-slow-ajaxsearch#dis-post-429817
<![CDATA[AjaxSearch order by TV ERROR]]> https://forums.modx.com/thread/76944/ajaxsearch-order-by-tv-error#dis-post-425418
Is it possible to order the values of the ajaxsearch on a TV? Basically I the results to be ordered by the TV(a date field TV) not by rabk.

I tried using the &order parameter but I get an error.
The date is displayed correctly in the output using the &tvPhx param.

The error I get is

« Execution of a query to the database failed - Unknown column 'researchPublicationDate' in 'order clause' »
      SQL: SELECT sc.id, sc.pagetitle, sc.longtitle, sc.description, sc.alias, sc.introtext, sc.template, sc.menutitle, sc.content, sc.publishedon, GROUP_CONCAT( DISTINCT CAST(ntv.id AS CHAR) SEPARATOR "," ) AS tv_id, GROUP_CONCAT( DISTINCT ntv.value SEPARATOR "," ) AS tv_value FROM `modx2_site_content` sc LEFT JOIN( SELECT DISTINCT tv.id, tv.value, tv.contentid FROM `modx2_site_tmplvar_contentvalues` tv ) AS ntv ON sc.id = ntv.contentid WHERE ((sc.id IN (404,405,406)) AND (sc.published=1) AND (sc.searchable=1) AND (sc.deleted=0) AND (sc.privateweb=0)) GROUP BY sc.id HAVING (((sc.pagetitle LIKE '%entry%') OR (sc.longtitle LIKE '%entry%') OR (sc.description LIKE '%entry%') OR (sc.alias LIKE '%entry%') OR (sc.introtext LIKE '%entry%') OR (sc.menutitle LIKE '%entry%') OR (sc.content LIKE '%entry%') OR (tv_value LIKE '%entry%'))) ORDER BY researchPublicationDate


I was hopping that AjaxSearch would build the query in a way that get the researchPublicationDate TV as a column.

Thank you]]>
https://forums.modx.com/thread/76944/ajaxsearch-order-by-tv-error#dis-post-425418 Thu, 31 May 2012 04:23:53 +0000 https://forums.modx.com/thread/76944/ajaxsearch-order-by-tv-error#dis-post-425418